// source --> https://tobet88.tv/wp-includes/js/jquery/jquery.js?ver=1.12.4-wp /*! jQuery v1.12.4 | (c) jQuery Foundation | jquery.org/license | WordPress 2019-05-16 */ !function(a,b){"object"==typeof module&&"object"==typeof module.exports?module.exports=a.document?b(a,!0):function(a){if(!a.document)throw new Error("jQuery requires a window with a document");return b(a)}:b(a)}("undefined"!=typeof window?window:this,function(a,b){var c=[],d=a.document,e=c.slice,f=c.concat,g=c.push,h=c.indexOf,i={},j=i.toString,k=i.hasOwnProperty,l={},m="1.12.4",n=function(a,b){return new n.fn.init(a,b)},o=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,p=/^-ms-/,q=/-([\da-z])/gi,r=function(a,b){return b.toUpperCase()};n.fn=n.prototype={jquery:m,constructor:n,selector:"",length:0,toArray:function(){return e.call(this)},get:function(a){return null!=a?a<0?this[a+this.length]:this[a]:e.call(this)},pushStack:function(a){var b=n.merge(this.constructor(),a);return b.prevObject=this,b.context=this.context,b},each:function(a){return n.each(this,a)},map:function(a){return this.pushStack(n.map(this,function(b,c){return a.call(b,c,b)}))},slice:function(){return this.pushStack(e.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(a){var b=this.length,c=+a+(a<0?b:0);return this.pushStack(c>=0&&c=0},isEmptyObject:function(a){var b;for(b in a)return!1;return!0},isPlainObject:function(a){var b;if(!a||"object"!==n.type(a)||a.nodeType||n.isWindow(a))return!1;try{if(a.constructor&&!k.call(a,"constructor")&&!k.call(a.constructor.prototype,"isPrototypeOf"))return!1}catch(c){return!1}if(!l.ownFirst)for(b in a)return k.call(a,b);for(b in a);return void 0===b||k.call(a,b)},type:function(a){return null==a?a+"":"object"==typeof a||"function"==typeof a?i[j.call(a)]||"object":typeof a},globalEval:function(b){b&&n.trim(b)&&(a.execScript||function(b){a.eval.call(a,b)})(b)},camelCase:function(a){return a.replace(p,"ms-").replace(q,r)},nodeName:function(a,b){return a.nodeName&&a.nodeName.toLowerCase()===b.toLowerCase()},each:function(a,b){var c,d=0;if(s(a)){for(c=a.length;d0&&b-1 in a)}var t=function(a){var b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u="sizzle"+1*new Date,v=a.document,w=0,x=0,y=fa(),z=fa(),A=fa(),B=function(a,b){return a===b&&(l=!0),0},C=1<<31,D={}.hasOwnProperty,E=[],F=E.pop,G=E.push,H=E.push,I=E.slice,J=function(a,b){for(var c=0,d=a.length;c+~]|"+L+")"+L+"*"),T=new RegExp("="+L+"*([^\\]'\"]*?)"+L+"*\\]","g"),U=new RegExp(O),V=new RegExp("^"+M+"$"),W={ID:new RegExp("^#("+M+")"),CLASS:new RegExp("^\\.("+M+")"),TAG:new RegExp("^("+M+"|[*])"),ATTR:new RegExp("^"+N),PSEUDO:new RegExp("^"+O),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+L+"*(even|odd|(([+-]|)(\\d*)n|)"+L+"*(?:([+-]|)"+L+"*(\\d+)|))"+L+"*\\)|)","i"),bool:new RegExp("^(?:"+K+")$","i"),needsContext:new RegExp("^"+L+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+L+"*((?:-\\d)?\\d*)"+L+"*\\)|)(?=[^-]|$)","i")},X=/^(?:input|select|textarea|button)$/i,Y=/^h\d$/i,Z=/^[^{]+\{\s*\[native \w/,$=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,_=/[+~]/,aa=/'|\\/g,ba=new RegExp("\\\\([\\da-f]{1,6}"+L+"?|("+L+")|.)","ig"),ca=function(a,b,c){var d="0x"+b-65536;return d!==d||c?b:d<0?String.fromCharCode(d+65536):String.fromCharCode(d>>10|55296,1023&d|56320)},da=function(){m()};try{H.apply(E=I.call(v.childNodes),v.childNodes),E[v.childNodes.length].nodeType}catch(xa){H={apply:E.length?function(a,b){G.apply(a,I.call(b))}:function(a,b){var c=a.length,d=0;while(a[c++]=b[d++]);a.length=c-1}}}function ea(a,b,d,e){var f,h,j,k,l,o,r,s,w=b&&b.ownerDocument,x=b?b.nodeType:9;if(d=d||[],"string"!=typeof a||!a||1!==x&&9!==x&&11!==x)return d;if(!e&&((b?b.ownerDocument||b:v)!==n&&m(b),b=b||n,p)){if(11!==x&&(o=$.exec(a)))if(f=o[1]){if(9===x){if(!(j=b.getElementById(f)))return d;if(j.id===f)return d.push(j),d}else if(w&&(j=w.getElementById(f))&&t(b,j)&&j.id===f)return d.push(j),d}else{if(o[2])return H.apply(d,b.getElementsByTagName(a)),d;if((f=o[3])&&c.getElementsByClassName&&b.getElementsByClassName)return H.apply(d,b.getElementsByClassName(f)),d}if(c.qsa&&!A[a+" "]&&(!q||!q.test(a))){if(1!==x)w=b,s=a;else if("object"!==b.nodeName.toLowerCase()){(k=b.getAttribute("id"))?k=k.replace(aa,"\\$&"):b.setAttribute("id",k=u),r=g(a),h=r.length,l=V.test(k)?"#"+k:"[id='"+k+"']";while(h--)r[h]=l+" "+pa(r[h]);s=r.join(","),w=_.test(a)&&na(b.parentNode)||b}if(s)try{return H.apply(d,w.querySelectorAll(s)),d}catch(y){}finally{k===u&&b.removeAttribute("id")}}}return i(a.replace(Q,"$1"),b,d,e)}function fa(){var a=[];function b(c,e){return a.push(c+" ")>d.cacheLength&&delete b[a.shift()],b[c+" "]=e}return b}function ga(a){return a[u]=!0,a}function ha(a){var b=n.createElement("div");try{return!!a(b)}catch(xa){return!1}finally{b.parentNode&&b.parentNode.removeChild(b),b=null}}function ia(a,b){var c=a.split("|"),e=c.length;while(e--)d.attrHandle[c[e]]=b}function ja(a,b){var c=b&&a,d=c&&1===a.nodeType&&1===b.nodeType&&(~b.sourceIndex||C)-(~a.sourceIndex||C);if(d)return d;if(c)while(c=c.nextSibling)if(c===b)return-1;return a?1:-1}function ka(a){return function(b){return"input"===b.nodeName.toLowerCase()&&b.type===a}}function la(a){return function(b){var c=b.nodeName.toLowerCase();return("input"===c||"button"===c)&&b.type===a}}function ma(a){return ga(function(b){return b=+b,ga(function(c,d){var e,f=a([],c.length,b),g=f.length;while(g--)c[e=f[g]]&&(c[e]=!(d[e]=c[e]))})})}function na(a){return a&&void 0!==a.getElementsByTagName&&a}c=ea.support={},f=ea.isXML=function(a){var b=a&&(a.ownerDocument||a).documentElement;return!!b&&"HTML"!==b.nodeName},m=ea.setDocument=function(a){var b,e,g=a?a.ownerDocument||a:v;return g!==n&&9===g.nodeType&&g.documentElement?(n=g,o=n.documentElement,p=!f(n),(e=n.defaultView)&&e.top!==e&&(e.addEventListener?e.addEventListener("unload",da,!1):e.attachEvent&&e.attachEvent("onunload",da)),c.attributes=ha(function(a){return a.className="i",!a.getAttribute("className")}),c.getElementsByTagName=ha(function(a){return a.appendChild(n.createComment("")),!a.getElementsByTagName("*").length}),c.getElementsByClassName=Z.test(n.getElementsByClassName),c.getById=ha(function(a){return o.appendChild(a).id=u,!n.getElementsByName||!n.getElementsByName(u).length}),c.getById?(d.find.ID=function(a,b){if(void 0!==b.getElementById&&p){var c=b.getElementById(a);return c?[c]:[]}},d.filter.ID=function(a){var b=a.replace(ba,ca);return function(a){return a.getAttribute("id")===b}}):(delete d.find.ID,d.filter.ID=function(a){var b=a.replace(ba,ca);return function(a){var c=void 0!==a.getAttributeNode&&a.getAttributeNode("id");return c&&c.value===b}}),d.find.TAG=c.getElementsByTagName?function(a,b){return void 0!==b.getElementsByTagName?b.getElementsByTagName(a):c.qsa?b.querySelectorAll(a):void 0}:function(a,b){var c,d=[],e=0,f=b.getElementsByTagName(a);if("*"===a){while(c=f[e++])1===c.nodeType&&d.push(c);return d}return f},d.find.CLASS=c.getElementsByClassName&&function(a,b){if(void 0!==b.getElementsByClassName&&p)return b.getElementsByClassName(a)},r=[],q=[],(c.qsa=Z.test(n.querySelectorAll))&&(ha(function(a){o.appendChild(a).innerHTML="",a.querySelectorAll("[msallowcapture^='']").length&&q.push("[*^$]="+L+"*(?:''|\"\")"),a.querySelectorAll("[selected]").length||q.push("\\["+L+"*(?:value|"+K+")"),a.querySelectorAll("[id~="+u+"-]").length||q.push("~="),a.querySelectorAll(":checked").length||q.push(":checked"),a.querySelectorAll("a#"+u+"+*").length||q.push(".#.+[+~]")}),ha(function(a){var b=n.createElement("input");b.setAttribute("type","hidden"),a.appendChild(b).setAttribute("name","D"),a.querySelectorAll("[name=d]").length&&q.push("name"+L+"*[*^$|!~]?="),a.querySelectorAll(":enabled").length||q.push(":enabled",":disabled"),a.querySelectorAll("*,:x"),q.push(",.*:")})),(c.matchesSelector=Z.test(s=o.matches||o.webkitMatchesSelector||o.mozMatchesSelector||o.oMatchesSelector||o.msMatchesSelector))&&ha(function(a){c.disconnectedMatch=s.call(a,"div"),s.call(a,"[s!='']:x"),r.push("!=",O)}),q=q.length&&new RegExp(q.join("|")),r=r.length&&new RegExp(r.join("|")),b=Z.test(o.compareDocumentPosition),t=b||Z.test(o.contains)?function(a,b){var c=9===a.nodeType?a.documentElement:a,d=b&&b.parentNode;return a===d||!(!d||1!==d.nodeType||!(c.contains?c.contains(d):a.compareDocumentPosition&&16&a.compareDocumentPosition(d)))}:function(a,b){if(b)while(b=b.parentNode)if(b===a)return!0;return!1},B=b?function(a,b){if(a===b)return l=!0,0;var d=!a.compareDocumentPosition-!b.compareDocumentPosition;return d||(d=(a.ownerDocument||a)===(b.ownerDocument||b)?a.compareDocumentPosition(b):1,1&d||!c.sortDetached&&b.compareDocumentPosition(a)===d?a===n||a.ownerDocument===v&&t(v,a)?-1:b===n||b.ownerDocument===v&&t(v,b)?1:k?J(k,a)-J(k,b):0:4&d?-1:1)}:function(a,b){if(a===b)return l=!0,0;var c,d=0,e=a.parentNode,f=b.parentNode,g=[a],h=[b];if(!e||!f)return a===n?-1:b===n?1:e?-1:f?1:k?J(k,a)-J(k,b):0;if(e===f)return ja(a,b);c=a;while(c=c.parentNode)g.unshift(c);c=b;while(c=c.parentNode)h.unshift(c);while(g[d]===h[d])d++;return d?ja(g[d],h[d]):g[d]===v?-1:h[d]===v?1:0},n):n},ea.matches=function(a,b){return ea(a,null,null,b)},ea.matchesSelector=function(a,b){if((a.ownerDocument||a)!==n&&m(a),b=b.replace(T,"='$1']"),c.matchesSelector&&p&&!A[b+" "]&&(!r||!r.test(b))&&(!q||!q.test(b)))try{var d=s.call(a,b);if(d||c.disconnectedMatch||a.document&&11!==a.document.nodeType)return d}catch(xa){}return ea(b,n,null,[a]).length>0},ea.contains=function(a,b){return(a.ownerDocument||a)!==n&&m(a),t(a,b)},ea.attr=function(a,b){(a.ownerDocument||a)!==n&&m(a);var e=d.attrHandle[b.toLowerCase()],f=e&&D.call(d.attrHandle,b.toLowerCase())?e(a,b,!p):void 0;return void 0!==f?f:c.attributes||!p?a.getAttribute(b):(f=a.getAttributeNode(b))&&f.specified?f.value:null},ea.error=function(a){throw new Error("Syntax error, unrecognized expression: "+a)},ea.uniqueSort=function(a){var b,d=[],e=0,f=0;if(l=!c.detectDuplicates,k=!c.sortStable&&a.slice(0),a.sort(B),l){while(b=a[f++])b===a[f]&&(e=d.push(f));while(e--)a.splice(d[e],1)}return k=null,a},e=ea.getText=function(a){var b,c="",d=0,f=a.nodeType;if(f){if(1===f||9===f||11===f){if("string"==typeof a.textContent)return a.textContent;for(a=a.firstChild;a;a=a.nextSibling)c+=e(a)}else if(3===f||4===f)return a.nodeValue}else while(b=a[d++])c+=e(b);return c},d=ea.selectors={cacheLength:50,createPseudo:ga,match:W,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(a){return a[1]=a[1].replace(ba,ca),a[3]=(a[3]||a[4]||a[5]||"").replace(ba,ca),"~="===a[2]&&(a[3]=" "+a[3]+" "),a.slice(0,4)},CHILD:function(a){return a[1]=a[1].toLowerCase(),"nth"===a[1].slice(0,3)?(a[3]||ea.error(a[0]),a[4]=+(a[4]?a[5]+(a[6]||1):2*("even"===a[3]||"odd"===a[3])),a[5]=+(a[7]+a[8]||"odd"===a[3])):a[3]&&ea.error(a[0]),a},PSEUDO:function(a){var b,c=!a[6]&&a[2];return W.CHILD.test(a[0])?null:(a[3]?a[2]=a[4]||a[5]||"":c&&U.test(c)&&(b=g(c,!0))&&(b=c.indexOf(")",c.length-b)-c.length)&&(a[0]=a[0].slice(0,b),a[2]=c.slice(0,b)),a.slice(0,3))}},filter:{TAG:function(a){var b=a.replace(ba,ca).toLowerCase();return"*"===a?function(){return!0}:function(a){return a.nodeName&&a.nodeName.toLowerCase()===b}},CLASS:function(a){var b=y[a+" "];return b||(b=new RegExp("(^|"+L+")"+a+"("+L+"|$)"))&&y(a,function(a){return b.test("string"==typeof a.className&&a.className||void 0!==a.getAttribute&&a.getAttribute("class")||"")})},ATTR:function(a,b,c){return function(d){var e=ea.attr(d,a);return null==e?"!="===b:!b||(e+="","="===b?e===c:"!="===b?e!==c:"^="===b?c&&0===e.indexOf(c):"*="===b?c&&e.indexOf(c)>-1:"$="===b?c&&e.slice(-c.length)===c:"~="===b?(" "+e.replace(P," ")+" ").indexOf(c)>-1:"|="===b&&(e===c||e.slice(0,c.length+1)===c+"-"))}},CHILD:function(a,b,c,d,e){var f="nth"!==a.slice(0,3),g="last"!==a.slice(-4),h="of-type"===b;return 1===d&&0===e?function(a){return!!a.parentNode}:function(b,c,i){var j,k,l,m,n,o,p=f!==g?"nextSibling":"previousSibling",q=b.parentNode,r=h&&b.nodeName.toLowerCase(),s=!i&&!h,t=!1;if(q){if(f){while(p){m=b;while(m=m[p])if(h?m.nodeName.toLowerCase()===r:1===m.nodeType)return!1;o=p="only"===a&&!o&&"nextSibling"}return!0}if(o=[g?q.firstChild:q.lastChild],g&&s){m=q,l=m[u]||(m[u]={}),k=l[m.uniqueID]||(l[m.uniqueID]={}),j=k[a]||[],n=j[0]===w&&j[1],t=n&&j[2],m=n&&q.childNodes[n];while(m=++n&&m&&m[p]||(t=n=0)||o.pop())if(1===m.nodeType&&++t&&m===b){k[a]=[w,n,t];break}}else if(s&&(m=b,l=m[u]||(m[u]={}),k=l[m.uniqueID]||(l[m.uniqueID]={}),j=k[a]||[],n=j[0]===w&&j[1],t=n),!1===t)while(m=++n&&m&&m[p]||(t=n=0)||o.pop())if((h?m.nodeName.toLowerCase()===r:1===m.nodeType)&&++t&&(s&&(l=m[u]||(m[u]={}),k=l[m.uniqueID]||(l[m.uniqueID]={}),k[a]=[w,t]),m===b))break;return(t-=e)===d||t%d==0&&t/d>=0}}},PSEUDO:function(a,b){var c,e=d.pseudos[a]||d.setFilters[a.toLowerCase()]||ea.error("unsupported pseudo: "+a);return e[u]?e(b):e.length>1?(c=[a,a,"",b],d.setFilters.hasOwnProperty(a.toLowerCase())?ga(function(a,c){var d,f=e(a,b),g=f.length;while(g--)d=J(a,f[g]),a[d]=!(c[d]=f[g])}):function(a){return e(a,0,c)}):e}},pseudos:{not:ga(function(a){var b=[],c=[],d=h(a.replace(Q,"$1"));return d[u]?ga(function(a,b,c,e){var f,g=d(a,null,e,[]),h=a.length;while(h--)(f=g[h])&&(a[h]=!(b[h]=f))}):function(a,e,f){return b[0]=a,d(b,null,f,c),b[0]=null,!c.pop()}}),has:ga(function(a){return function(b){return ea(a,b).length>0}}),contains:ga(function(a){return a=a.replace(ba,ca),function(b){return(b.textContent||b.innerText||e(b)).indexOf(a)>-1}}),lang:ga(function(a){return V.test(a||"")||ea.error("unsupported lang: "+a),a=a.replace(ba,ca).toLowerCase(),function(b){var c;do{if(c=p?b.lang:b.getAttribute("xml:lang")||b.getAttribute("lang"))return(c=c.toLowerCase())===a||0===c.indexOf(a+"-")}while((b=b.parentNode)&&1===b.nodeType);return!1}}),target:function(b){var c=a.location&&a.location.hash;return c&&c.slice(1)===b.id},root:function(a){return a===o},focus:function(a){return a===n.activeElement&&(!n.hasFocus||n.hasFocus())&&!!(a.type||a.href||~a.tabIndex)},enabled:function(a){return!1===a.disabled},disabled:function(a){return!0===a.disabled},checked:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&!!a.checked||"option"===b&&!!a.selected},selected:function(a){return a.parentNode&&a.parentNode.selectedIndex,!0===a.selected},empty:function(a){for(a=a.firstChild;a;a=a.nextSibling)if(a.nodeType<6)return!1;return!0},parent:function(a){return!d.pseudos.empty(a)},header:function(a){return Y.test(a.nodeName)},input:function(a){return X.test(a.nodeName)},button:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&"button"===a.type||"button"===b},text:function(a){var b;return"input"===a.nodeName.toLowerCase()&&"text"===a.type&&(null==(b=a.getAttribute("type"))||"text"===b.toLowerCase())},first:ma(function(){return[0]}),last:ma(function(a,b){return[b-1]}),eq:ma(function(a,b,c){return[c<0?c+b:c]}),even:ma(function(a,b){for(var c=0;c=0;)a.push(d);return a}),gt:ma(function(a,b,c){for(var d=c<0?c+b:c;++d1?function(b,c,d){var e=a.length;while(e--)if(!a[e](b,c,d))return!1;return!0}:a[0]}function sa(a,b,c){for(var d=0,e=b.length;d-1&&(f[j]=!(g[j]=l))}}else r=ta(r===g?r.splice(o,r.length):r),e?e(null,g,r,i):H.apply(g,r)})}function va(a){for(var b,c,e,f=a.length,g=d.relative[a[0].type],h=g||d.relative[" "],i=g?1:0,k=qa(function(a){return a===b},h,!0),l=qa(function(a){return J(b,a)>-1},h,!0),m=[function(a,c,d){var e=!g&&(d||c!==j)||((b=c).nodeType?k(a,c,d):l(a,c,d));return b=null,e}];i1&&ra(m),i>1&&pa(a.slice(0,i-1).concat({value:" "===a[i-2].type?"*":""})).replace(Q,"$1"),c,i0,e=a.length>0,f=function(f,g,h,i,k){var l,o,q,r=0,s="0",t=f&&[],u=[],v=j,x=f||e&&d.find.TAG("*",k),y=w+=null==v?1:Math.random()||.1,z=x.length;for(k&&(j=g===n||g||k);s!==z&&null!=(l=x[s]);s++){if(e&&l){o=0,g||l.ownerDocument===n||(m(l),h=!p);while(q=a[o++])if(q(l,g||n,h)){i.push(l);break}k&&(w=y)}c&&((l=!q&&l)&&r--,f&&t.push(l))}if(r+=s,c&&s!==r){o=0;while(q=b[o++])q(t,u,g,h);if(f){if(r>0)while(s--)t[s]||u[s]||(u[s]=F.call(i));u=ta(u)}H.apply(i,u),k&&!f&&u.length>0&&r+b.length>1&&ea.uniqueSort(i)}return k&&(w=y,j=v),t};return c?ga(f):f}return h=ea.compile=function(a,b){var c,d=[],e=[],f=A[a+" "];if(!f){b||(b=g(a)),c=b.length;while(c--)f=va(b[c]),f[u]?d.push(f):e.push(f);f=A(a,wa(e,d)),f.selector=a}return f},i=ea.select=function(a,b,e,f){var i,j,k,l,m,n="function"==typeof a&&a,o=!f&&g(a=n.selector||a);if(e=e||[],1===o.length){if(j=o[0]=o[0].slice(0),j.length>2&&"ID"===(k=j[0]).type&&c.getById&&9===b.nodeType&&p&&d.relative[j[1].type]){if(!(b=(d.find.ID(k.matches[0].replace(ba,ca),b)||[])[0]))return e;n&&(b=b.parentNode),a=a.slice(j.shift().value.length)}i=W.needsContext.test(a)?0:j.length;while(i--){if(k=j[i],d.relative[l=k.type])break;if((m=d.find[l])&&(f=m(k.matches[0].replace(ba,ca),_.test(j[0].type)&&na(b.parentNode)||b))){if(j.splice(i,1),!(a=f.length&&pa(j)))return H.apply(e,f),e;break}}}return(n||h(a,o))(f,b,!p,e,!b||_.test(a)&&na(b.parentNode)||b),e},c.sortStable=u.split("").sort(B).join("")===u,c.detectDuplicates=!!l,m(),c.sortDetached=ha(function(a){return 1&a.compareDocumentPosition(n.createElement("div"))}),ha(function(a){return a.innerHTML="","#"===a.firstChild.getAttribute("href")})||ia("type|href|height|width",function(a,b,c){if(!c)return a.getAttribute(b,"type"===b.toLowerCase()?1:2)}),c.attributes&&ha(function(a){return a.innerHTML="",a.firstChild.setAttribute("value",""),""===a.firstChild.getAttribute("value")})||ia("value",function(a,b,c){if(!c&&"input"===a.nodeName.toLowerCase())return a.defaultValue}),ha(function(a){return null==a.getAttribute("disabled")})||ia(K,function(a,b,c){var d;if(!c)return!0===a[b]?b.toLowerCase():(d=a.getAttributeNode(b))&&d.specified?d.value:null}),ea}(a);n.find=t,n.expr=t.selectors,n.expr[":"]=n.expr.pseudos,n.uniqueSort=n.unique=t.uniqueSort,n.text=t.getText,n.isXMLDoc=t.isXML,n.contains=t.contains;var u=function(a,b,c){var d=[],e=void 0!==c;while((a=a[b])&&9!==a.nodeType)if(1===a.nodeType){if(e&&n(a).is(c))break;d.push(a)}return d},v=function(a,b){for(var c=[];a;a=a.nextSibling)1===a.nodeType&&a!==b&&c.push(a);return c},w=n.expr.match.needsContext,x=/^<([\w-]+)\s*\/?>(?:<\/\1>|)$/,y=/^.[^:#\[\.,]*$/;function z(a,b,c){if(n.isFunction(b))return n.grep(a,function(a,d){return!!b.call(a,d,a)!==c});if(b.nodeType)return n.grep(a,function(a){return a===b!==c});if("string"==typeof b){if(y.test(b))return n.filter(b,a,c);b=n.filter(b,a)}return n.grep(a,function(a){return n.inArray(a,b)>-1!==c})}n.filter=function(a,b,c){var d=b[0];return c&&(a=":not("+a+")"),1===b.length&&1===d.nodeType?n.find.matchesSelector(d,a)?[d]:[]:n.find.matches(a,n.grep(b,function(a){return 1===a.nodeType}))},n.fn.extend({find:function(a){var b,c=[],d=this,e=d.length;if("string"!=typeof a)return this.pushStack(n(a).filter(function(){for(b=0;b1?n.unique(c):c),c.selector=this.selector?this.selector+" "+a:a,c},filter:function(a){return this.pushStack(z(this,a||[],!1))},not:function(a){return this.pushStack(z(this,a||[],!0))},is:function(a){return!!z(this,"string"==typeof a&&w.test(a)?n(a):a||[],!1).length}});var A,B=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]*))$/;(n.fn.init=function(a,b,c){var e,f;if(!a)return this;if(c=c||A,"string"==typeof a){if(!(e="<"===a.charAt(0)&&">"===a.charAt(a.length-1)&&a.length>=3?[null,a,null]:B.exec(a))||!e[1]&&b)return!b||b.jquery?(b||c).find(a):this.constructor(b).find(a);if(e[1]){if(b=b instanceof n?b[0]:b,n.merge(this,n.parseHTML(e[1],b&&b.nodeType?b.ownerDocument||b:d,!0)),x.test(e[1])&&n.isPlainObject(b))for(e in b)n.isFunction(this[e])?this[e](b[e]):this.attr(e,b[e]);return this}if((f=d.getElementById(e[2]))&&f.parentNode){if(f.id!==e[2])return A.find(a);this.length=1,this[0]=f}return this.context=d,this.selector=a,this}return a.nodeType?(this.context=this[0]=a,this.length=1,this):n.isFunction(a)?void 0!==c.ready?c.ready(a):a(n):(void 0!==a.selector&&(this.selector=a.selector,this.context=a.context),n.makeArray(a,this))}).prototype=n.fn,A=n(d);var C=/^(?:parents|prev(?:Until|All))/,D={children:!0,contents:!0,next:!0,prev:!0};n.fn.extend({has:function(a){var b,c=n(a,this),d=c.length;return this.filter(function(){for(b=0;b-1:1===c.nodeType&&n.find.matchesSelector(c,a))){f.push(c);break}return this.pushStack(f.length>1?n.uniqueSort(f):f)},index:function(a){return a?"string"==typeof a?n.inArray(this[0],n(a)):n.inArray(a.jquery?a[0]:a,this):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(a,b){return this.pushStack(n.uniqueSort(n.merge(this.get(),n(a,b))))},addBack:function(a){return this.add(null==a?this.prevObject:this.prevObject.filter(a))}});function E(a,b){do{a=a[b]}while(a&&1!==a.nodeType);return a}n.each({parent:function(a){var b=a.parentNode;return b&&11!==b.nodeType?b:null},parents:function(a){return u(a,"parentNode")},parentsUntil:function(a,b,c){return u(a,"parentNode",c)},next:function(a){return E(a,"nextSibling")},prev:function(a){return E(a,"previousSibling")},nextAll:function(a){return u(a,"nextSibling")},prevAll:function(a){return u(a,"previousSibling")},nextUntil:function(a,b,c){return u(a,"nextSibling",c)},prevUntil:function(a,b,c){return u(a,"previousSibling",c)},siblings:function(a){return v((a.parentNode||{}).firstChild,a)},children:function(a){return v(a.firstChild)},contents:function(a){return n.nodeName(a,"iframe")?a.contentDocument||a.contentWindow.document:n.merge([],a.childNodes)}},function(a,b){n.fn[a]=function(c,d){var e=n.map(this,b,c);return"Until"!==a.slice(-5)&&(d=c),d&&"string"==typeof d&&(e=n.filter(d,e)),this.length>1&&(D[a]||(e=n.uniqueSort(e)),C.test(a)&&(e=e.reverse())),this.pushStack(e)}});var F=/\S+/g;function G(a){var b={};return n.each(a.match(F)||[],function(a,c){b[c]=!0}),b}n.Callbacks=function(a){a="string"==typeof a?G(a):n.extend({},a);var b,c,d,e,f=[],g=[],h=-1,i=function(){for(e=a.once,d=b=!0;g.length;h=-1){c=g.shift();while(++h-1)f.splice(c,1),c<=h&&h--}),this},has:function(a){return a?n.inArray(a,f)>-1:f.length>0},empty:function(){return f&&(f=[]),this},disable:function(){return e=g=[],f=c="",this},disabled:function(){return!f},lock:function(){return e=!0,c||j.disable(),this},locked:function(){return!!e},fireWith:function(a,c){return e||(c=c||[],c=[a,c.slice?c.slice():c],g.push(c),b||i()),this},fire:function(){return j.fireWith(this,arguments),this},fired:function(){return!!d}};return j},n.extend({Deferred:function(a){var b=[["resolve","done",n.Callbacks("once memory"),"resolved"],["reject","fail",n.Callbacks("once memory"),"rejected"],["notify","progress",n.Callbacks("memory")]],c="pending",d={state:function(){return c},always:function(){return e.done(arguments).fail(arguments),this},then:function(){var a=arguments;return n.Deferred(function(c){n.each(b,function(b,f){var g=n.isFunction(a[b])&&a[b];e[f[1]](function(){var a=g&&g.apply(this,arguments);a&&n.isFunction(a.promise)?a.promise().progress(c.notify).done(c.resolve).fail(c.reject):c[f[0]+"With"](this===d?c.promise():this,g?[a]:arguments)})}),a=null}).promise()},promise:function(a){return null!=a?n.extend(a,d):d}},e={};return d.pipe=d.then,n.each(b,function(a,f){var g=f[2],h=f[3];d[f[1]]=g.add,h&&g.add(function(){c=h},b[1^a][2].disable,b[2][2].lock),e[f[0]]=function(){return e[f[0]+"With"](this===e?d:this,arguments),this},e[f[0]+"With"]=g.fireWith}),d.promise(e),a&&a.call(e,e),e},when:function(a){var b=0,c=e.call(arguments),d=c.length,f=1!==d||a&&n.isFunction(a.promise)?d:0,g=1===f?a:n.Deferred(),h=function(a,b,c){return function(d){b[a]=this,c[a]=arguments.length>1?e.call(arguments):d,c===i?g.notifyWith(b,c):--f||g.resolveWith(b,c)}},i,j,k;if(d>1)for(i=new Array(d),j=new Array(d),k=new Array(d);b0||(H.resolveWith(d,[n]),n.fn.triggerHandler&&(n(d).triggerHandler("ready"),n(d).off("ready"))))}});function I(){d.addEventListener?(d.removeEventListener("DOMContentLoaded",J),a.removeEventListener("load",J)):(d.detachEvent("onreadystatechange",J),a.detachEvent("onload",J))}function J(){(d.addEventListener||"load"===a.event.type||"complete"===d.readyState)&&(I(),n.ready())}n.ready.promise=function(b){if(!H)if(H=n.Deferred(),"complete"===d.readyState||"loading"!==d.readyState&&!d.documentElement.doScroll)a.setTimeout(n.ready);else if(d.addEventListener)d.addEventListener("DOMContentLoaded",J),a.addEventListener("load",J);else{d.attachEvent("onreadystatechange",J),a.attachEvent("onload",J);var c=!1;try{c=null==a.frameElement&&d.documentElement}catch(e){}c&&c.doScroll&&function b(){if(!n.isReady){try{c.doScroll("left")}catch(e){return a.setTimeout(b,50)}I(),n.ready()}}()}return H.promise(b)},n.ready.promise();var K;for(K in n(l))break;l.ownFirst="0"===K,l.inlineBlockNeedsLayout=!1,n(function(){var a,b,c,e;(c=d.getElementsByTagName("body")[0])&&c.style&&(b=d.createElement("div"),e=d.createElement("div"),e.style.cssText="position:absolute;border:0;width:0;height:0;top:0;left:-9999px",c.appendChild(e).appendChild(b),void 0!==b.style.zoom&&(b.style.cssText="display:inline;margin:0;border:0;padding:1px;width:1px;zoom:1",l.inlineBlockNeedsLayout=a=3===b.offsetWidth,a&&(c.style.zoom=1)),c.removeChild(e))}),function(){var a=d.createElement("div");l.deleteExpando=!0;try{delete a.test}catch(b){l.deleteExpando=!1}a=null}();var L=function(a){var b=n.noData[(a.nodeName+" ").toLowerCase()],c=+a.nodeType||1;return(1===c||9===c)&&(!b||!0!==b&&a.getAttribute("classid")===b)},M=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,N=/([A-Z])/g;function O(a,b,c){if(void 0===c&&1===a.nodeType){var d="data-"+b.replace(N,"-$1").toLowerCase();if("string"==typeof(c=a.getAttribute(d))){try{c="true"===c||"false"!==c&&("null"===c?null:+c+""===c?+c:M.test(c)?n.parseJSON(c):c)}catch(e){}n.data(a,b,c)}else c=void 0}return c}function P(a){var b ;for(b in a)if(("data"!==b||!n.isEmptyObject(a[b]))&&"toJSON"!==b)return!1;return!0}function Q(a,b,d,e){if(L(a)){var f,g,h=n.expando,i=a.nodeType,j=i?n.cache:a,k=i?a[h]:a[h]&&h;if(k&&j[k]&&(e||j[k].data)||void 0!==d||"string"!=typeof b)return k||(k=i?a[h]=c.pop()||n.guid++:h),j[k]||(j[k]=i?{}:{toJSON:n.noop}),"object"!=typeof b&&"function"!=typeof b||(e?j[k]=n.extend(j[k],b):j[k].data=n.extend(j[k].data,b)),g=j[k],e||(g.data||(g.data={}),g=g.data),void 0!==d&&(g[n.camelCase(b)]=d),"string"==typeof b?null==(f=g[b])&&(f=g[n.camelCase(b)]):f=g,f}}function R(a,b,c){if(L(a)){var d,e,f=a.nodeType,g=f?n.cache:a,h=f?a[n.expando]:n.expando;if(g[h]){if(b&&(d=c?g[h]:g[h].data)){n.isArray(b)?b=b.concat(n.map(b,n.camelCase)):b in d?b=[b]:(b=n.camelCase(b),b=b in d?[b]:b.split(" ")),e=b.length;while(e--)delete d[b[e]];if(c?!P(d):!n.isEmptyObject(d))return}(c||(delete g[h].data,P(g[h])))&&(f?n.cleanData([a],!0):l.deleteExpando||g!=g.window?delete g[h]:g[h]=void 0)}}}n.extend({cache:{},noData:{"applet ":!0,"embed ":!0,"object ":"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"},hasData:function(a){return!!(a=a.nodeType?n.cache[a[n.expando]]:a[n.expando])&&!P(a)},data:function(a,b,c){return Q(a,b,c)},removeData:function(a,b){return R(a,b)},_data:function(a,b,c){return Q(a,b,c,!0)},_removeData:function(a,b){return R(a,b,!0)}}),n.fn.extend({data:function(a,b){var c,d,e,f=this[0],g=f&&f.attributes;if(void 0===a){if(this.length&&(e=n.data(f),1===f.nodeType&&!n._data(f,"parsedAttrs"))){c=g.length;while(c--)g[c]&&(d=g[c].name,0===d.indexOf("data-")&&(d=n.camelCase(d.slice(5)),O(f,d,e[d])));n._data(f,"parsedAttrs",!0)}return e}return"object"==typeof a?this.each(function(){n.data(this,a)}):arguments.length>1?this.each(function(){n.data(this,a,b)}):f?O(f,a,n.data(f,a)):void 0},removeData:function(a){return this.each(function(){n.removeData(this,a)})}}),n.extend({queue:function(a,b,c){var d;if(a)return b=(b||"fx")+"queue",d=n._data(a,b),c&&(!d||n.isArray(c)?d=n._data(a,b,n.makeArray(c)):d.push(c)),d||[]},dequeue:function(a,b){b=b||"fx";var c=n.queue(a,b),d=c.length,e=c.shift(),f=n._queueHooks(a,b),g=function(){n.dequeue(a,b)};"inprogress"===e&&(e=c.shift(),d--),e&&("fx"===b&&c.unshift("inprogress"),delete f.stop,e.call(a,g,f)),!d&&f&&f.empty.fire()},_queueHooks:function(a,b){var c=b+"queueHooks";return n._data(a,c)||n._data(a,c,{empty:n.Callbacks("once memory").add(function(){n._removeData(a,b+"queue"),n._removeData(a,c)})})}}),n.fn.extend({queue:function(a,b){var c=2;return"string"!=typeof a&&(b=a,a="fx",c--),arguments.length
a",l.leadingWhitespace=3===a.firstChild.nodeType,l.tbody=!a.getElementsByTagName("tbody").length,l.htmlSerialize=!!a.getElementsByTagName("link").length,l.html5Clone="<:nav>"!==d.createElement("nav").cloneNode(!0).outerHTML,c.type="checkbox",c.checked=!0,b.appendChild(c),l.appendChecked=c.checked,a.innerHTML="",l.noCloneChecked=!!a.cloneNode(!0).lastChild.defaultValue,b.appendChild(a),c=d.createElement("input"),c.setAttribute("type","radio"),c.setAttribute("checked","checked"),c.setAttribute("name","t"),a.appendChild(c),l.checkClone=a.cloneNode(!0).cloneNode(!0).lastChild.checked,l.noCloneEvent=!!a.addEventListener,a[n.expando]=1,l.attributes=!a.getAttribute(n.expando)}();var ca={option:[1,""],legend:[1,"
","
"],area:[1,"",""],param:[1,"",""],thead:[1,"","
"],tr:[2,"","
"],col:[2,"","
"],td:[3,"","
"],_default:l.htmlSerialize?[0,"",""]:[1,"X
","
"]};ca.optgroup=ca.option,ca.tbody=ca.tfoot=ca.colgroup=ca.caption=ca.thead,ca.th=ca.td;function da(a,b){var c,d,e=0,f=void 0!==a.getElementsByTagName?a.getElementsByTagName(b||"*"):void 0!==a.querySelectorAll?a.querySelectorAll(b||"*"):void 0;if(!f)for(f=[],c=a.childNodes||a;null!=(d=c[e]);e++)!b||n.nodeName(d,b)?f.push(d):n.merge(f,da(d,b));return void 0===b||b&&n.nodeName(a,b)?n.merge([a],f):f}function ea(a,b){for(var c,d=0;null!=(c=a[d]);d++)n._data(c,"globalEval",!b||n._data(b[d],"globalEval"))}var fa=/<|&#?\w+;/,ga=/"!==m[1]||ga.test(g)?0:i:i.firstChild,f=g&&g.childNodes.length;while(f--)n.nodeName(k=g.childNodes[f],"tbody")&&!k.childNodes.length&&g.removeChild(k)}n.merge(q,i.childNodes),i.textContent="";while(i.firstChild)i.removeChild(i.firstChild);i=p.lastChild}else q.push(b.createTextNode(g));i&&p.removeChild(i),l.appendChecked||n.grep(da(q,"input"),ha),r=0;while(g=q[r++])if(d&&n.inArray(g,d)>-1)e&&e.push(g);else if(h=n.contains(g.ownerDocument,g),i=da(p.appendChild(g),"script"),h&&ea(i),c){f=0;while(g=i[f++])$.test(g.type||"")&&c.push(g)}return i=null,p}!function(){var b,c,e=d.createElement("div");for(b in{submit:!0,change:!0,focusin:!0})c="on"+b,(l[b]=c in a)||(e.setAttribute(c,"t"),l[b]=!1===e.attributes[c].expando);e=null}();var ja=/^(?:input|select|textarea)$/i,ka=/^key/,la=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,ma=/^(?:focusinfocus|focusoutblur)$/,na=/^([^.]*)(?:\.(.+)|)/;function oa(){return!0}function pa(){return!1}function qa(){try{return d.activeElement}catch(a){}}function ra(a,b,c,d,e,f){var g,h;if("object"==typeof b){"string"!=typeof c&&(d=d||c,c=void 0);for(h in b)ra(a,h,c,d,b[h],f);return a}if(null==d&&null==e?(e=c,d=c=void 0):null==e&&("string"==typeof c?(e=d,d=void 0):(e=d,d=c,c=void 0)),!1===e)e=pa;else if(!e)return a;return 1===f&&(g=e,e=function(a){return n().off(a),g.apply(this,arguments)},e.guid=g.guid||(g.guid=n.guid++)),a.each(function(){n.event.add(this,b,e,d,c)})}n.event={global:{},add:function(a,b,c,d,e){var f,g,h,i,j,k,l,m,o,p,q,r=n._data(a);if(r){c.handler&&(i=c,c=i.handler,e=i.selector),c.guid||(c.guid=n.guid++),(g=r.events)||(g=r.events={}),(k=r.handle)||(k=r.handle=function(a){return void 0===n||a&&n.event.triggered===a.type?void 0:n.event.dispatch.apply(k.elem,arguments)},k.elem=a),b=(b||"").match(F)||[""],h=b.length;while(h--)f=na.exec(b[h])||[],o=q=f[1],p=(f[2]||"").split(".").sort(),o&&(j=n.event.special[o]||{},o=(e?j.delegateType:j.bindType)||o,j=n.event.special[o]||{},l=n.extend({type:o,origType:q,data:d,handler:c,guid:c.guid,selector:e,needsContext:e&&n.expr.match.needsContext.test(e),namespace:p.join(".")},i),(m=g[o])||(m=g[o]=[],m.delegateCount=0,j.setup&&!1!==j.setup.call(a,d,p,k)||(a.addEventListener?a.addEventListener(o,k,!1):a.attachEvent&&a.attachEvent("on"+o,k))),j.add&&(j.add.call(a,l),l.handler.guid||(l.handler.guid=c.guid)),e?m.splice(m.delegateCount++,0,l):m.push(l),n.event.global[o]=!0);a=null}},remove:function(a,b,c,d,e){var f,g,h,i,j,k,l,m,o,p,q,r=n.hasData(a)&&n._data(a);if(r&&(k=r.events)){b=(b||"").match(F)||[""],j=b.length;while(j--)if(h=na.exec(b[j])||[],o=q=h[1],p=(h[2]||"").split(".").sort(),o){l=n.event.special[o]||{},o=(d?l.delegateType:l.bindType)||o,m=k[o]||[],h=h[2]&&new RegExp("(^|\\.)"+p.join("\\.(?:.*\\.|)")+"(\\.|$)"),i=f=m.length;while(f--)g=m[f],!e&&q!==g.origType||c&&c.guid!==g.guid||h&&!h.test(g.namespace)||d&&d!==g.selector&&("**"!==d||!g.selector)||(m.splice(f,1),g.selector&&m.delegateCount--,l.remove&&l.remove.call(a,g));i&&!m.length&&(l.teardown&&!1!==l.teardown.call(a,p,r.handle)||n.removeEvent(a,o,r.handle),delete k[o])}else for(o in k)n.event.remove(a,o+b[j],c,d,!0);n.isEmptyObject(k)&&(delete r.handle,n._removeData(a,"events"))}},trigger:function(b,c,e,f){var g,h,i,j,l,m,o,p=[e||d],q=k.call(b,"type")?b.type:b,r=k.call(b,"namespace")?b.namespace.split("."):[];if(i=m=e=e||d,3!==e.nodeType&&8!==e.nodeType&&!ma.test(q+n.event.triggered)&&(q.indexOf(".")>-1&&(r=q.split("."),q=r.shift(),r.sort()),h=q.indexOf(":")<0&&"on"+q,b=b[n.expando]?b:new n.Event(q,"object"==typeof b&&b),b.isTrigger=f?2:3,b.namespace=r.join("."),b.rnamespace=b.namespace?new RegExp("(^|\\.)"+r.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,b.result=void 0,b.target||(b.target=e),c=null==c?[b]:n.makeArray(c,[b]),l=n.event.special[q]||{},f||!l.trigger||!1!==l.trigger.apply(e,c))){if(!f&&!l.noBubble&&!n.isWindow(e)){for(j=l.delegateType||q,ma.test(j+q)||(i=i.parentNode);i;i=i.parentNode)p.push(i),m=i;m===(e.ownerDocument||d)&&p.push(m.defaultView||m.parentWindow||a)}o=0;while((i=p[o++])&&!b.isPropagationStopped())b.type=o>1?j:l.bindType||q,g=(n._data(i,"events")||{})[b.type]&&n._data(i,"handle"),g&&g.apply(i,c),(g=h&&i[h])&&g.apply&&L(i)&&(b.result=g.apply(i,c),!1===b.result&&b.preventDefault());if(b.type=q,!f&&!b.isDefaultPrevented()&&(!l._default||!1===l._default.apply(p.pop(),c))&&L(e)&&h&&e[q]&&!n.isWindow(e)){m=e[h],m&&(e[h]=null),n.event.triggered=q;try{e[q]()}catch(s){}n.event.triggered=void 0,m&&(e[h]=m)}return b.result}},dispatch:function(a){a=n.event.fix(a);var b,c,d,f,g,h=[],i=e.call(arguments),j=(n._data(this,"events")||{})[a.type]||[],k=n.event.special[a.type]||{};if(i[0]=a,a.delegateTarget=this,!k.preDispatch||!1!==k.preDispatch.call(this,a)){h=n.event.handlers.call(this,a,j),b=0;while((f=h[b++])&&!a.isPropagationStopped()){a.currentTarget=f.elem,c=0;while((g=f.handlers[c++])&&!a.isImmediatePropagationStopped())a.rnamespace&&!a.rnamespace.test(g.namespace)||(a.handleObj=g,a.data=g.data,void 0!==(d=((n.event.special[g.origType]||{}).handle||g.handler).apply(f.elem,i))&&!1===(a.result=d)&&(a.preventDefault(),a.stopPropagation()))}return k.postDispatch&&k.postDispatch.call(this,a),a.result}},handlers:function(a,b){var c,d,e,f,g=[],h=b.delegateCount,i=a.target;if(h&&i.nodeType&&("click"!==a.type||isNaN(a.button)||a.button<1))for(;i!=this;i=i.parentNode||this)if(1===i.nodeType&&(!0!==i.disabled||"click"!==a.type)){for(d=[],c=0;c-1:n.find(e,this,null,[i]).length),d[e]&&d.push(f);d.length&&g.push({elem:i,handlers:d})}return h]","i"),ua=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:-]+)[^>]*)\/>/gi,va=/\s*$/g,za=ba(d),Aa=za.appendChild(d.createElement("div"));function Ba(a,b){return n.nodeName(a,"table")&&n.nodeName(11!==b.nodeType?b:b.firstChild,"tr")?a.getElementsByTagName("tbody")[0]||a.appendChild(a.ownerDocument.createElement("tbody")):a}function Ca(a){return a.type=(null!==n.find.attr(a,"type"))+"/"+a.type,a}function Da(a){var b=xa.exec(a.type);return b?a.type=b[1]:a.removeAttribute("type"),a}function Ea(a,b){if(1===b.nodeType&&n.hasData(a)){var c,d,e,f=n._data(a),g=n._data(b,f),h=f.events;if(h){delete g.handle,g.events={};for(c in h)for(d=0,e=h[c].length;d1&&"string"==typeof q&&!l.checkClone&&wa.test(q))return a.each(function(e){var f=a.eq(e);r&&(b[0]=q.call(this,e,f.html())),Ga(f,b,c,d)});if(o&&(k=ia(b,a[0].ownerDocument,!1,a,d),e=k.firstChild,1===k.childNodes.length&&(k=e),e||d)){for(i=n.map(da(k,"script"),Ca),h=i.length;m")},clone:function(a,b,c){var d,e,f,g,h,i=n.contains(a.ownerDocument,a);if(l.html5Clone||n.isXMLDoc(a)||!ta.test("<"+a.nodeName+">")?f=a.cloneNode(!0):(Aa.innerHTML=a.outerHTML,Aa.removeChild(f=Aa.firstChild)),!(l.noCloneEvent&&l.noCloneChecked||1!==a.nodeType&&11!==a.nodeType||n.isXMLDoc(a)))for(d=da(f),h=da(a),g=0;null!=(e=h[g]);++g)d[g]&&Fa(e,d[g]);if(b)if(c)for(h=h||da(a),d=d||da(f),g=0;null!=(e=h[g]);g++)Ea(e,d[g]);else Ea(a,f);return d=da(f,"script"),d.length>0&&ea(d,!i&&da(a,"script")),d=h=e=null,f},cleanData:function(a,b){for(var d,e,f,g,h=0,i=n.expando,j=n.cache,k=l.attributes,m=n.event.special;null!=(d=a[h]);h++)if((b||L(d))&&(f=d[i],g=f&&j[f])){if(g.events)for(e in g.events)m[e]?n.event.remove(d,e):n.removeEvent(d,e,g.handle);j[f]&&(delete j[f],k||void 0===d.removeAttribute?d[i]=void 0:d.removeAttribute(i),c.push(f))}}}),n.fn.extend({domManip:Ga,detach:function(a){return Ha(this,a,!0)},remove:function(a){return Ha(this,a)},text:function(a){return X(this,function(a){return void 0===a?n.text(this):this.empty().append((this[0]&&this[0].ownerDocument||d).createTextNode(a))},null,a,arguments.length)},append:function(){return Ga(this,arguments,function(a){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){Ba(this,a).appendChild(a)}})},prepend:function(){return Ga(this,arguments,function(a){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var b=Ba(this,a);b.insertBefore(a,b.firstChild)}})},before:function(){return Ga(this,arguments,function(a){this.parentNode&&this.parentNode.insertBefore(a,this)})},after:function(){return Ga(this,arguments,function(a){this.parentNode&&this.parentNode.insertBefore(a,this.nextSibling)})},empty:function(){for(var a,b=0;null!=(a=this[b]);b++){1===a.nodeType&&n.cleanData(da(a,!1));while(a.firstChild)a.removeChild(a.firstChild);a.options&&n.nodeName(a,"select")&&(a.options.length=0)}return this},clone:function(a,b){return a=null!=a&&a,b=null==b?a:b,this.map(function(){return n.clone(this,a,b)})},html:function(a){return X(this,function(a){var b=this[0]||{},c=0,d=this.length;if(void 0===a)return 1===b.nodeType?b.innerHTML.replace(sa,""):void 0;if("string"==typeof a&&!va.test(a)&&(l.htmlSerialize||!ta.test(a))&&(l.leadingWhitespace||!_.test(a))&&!ca[(Z.exec(a)||["",""])[1].toLowerCase()]){a=n.htmlPrefilter(a);try{for(;c")).appendTo(b.documentElement),b=(Ia[0].contentWindow||Ia[0].contentDocument).document,b.write(),b.close(),c=Ka(a,b),Ia.detach()),Ja[a]=c),c}var Ma=/^margin/,Na=new RegExp("^("+S+")(?!px)[a-z%]+$","i"),Oa=function(a,b,c,d){var e,f,g={};for(f in b)g[f]=a.style[f],a.style[f]=b[f];e=c.apply(a,d||[]);for(f in b)a.style[f]=g[f];return e},Pa=d.documentElement;!function(){var b,c,e,f,g,h,i=d.createElement("div"),j=d.createElement("div");function k(){var k,l,m=d.documentElement;m.appendChild(i),j.style.cssText="-webkit-box-sizing:border-box;box-sizing:border-box;position:relative;display:block;margin:auto;border:1px;padding:1px;top:1%;width:50%",b=e=h=!1,c=g=!0,a.getComputedStyle&&(l=a.getComputedStyle(j),b="1%"!==(l||{}).top,h="2px"===(l||{}).marginLeft,e="4px"===(l||{width:"4px"}).width,j.style.marginRight="50%",c="4px"===(l||{marginRight:"4px"}).marginRight,k=j.appendChild(d.createElement("div")),k.style.cssText=j.style.cssText="-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;display:block;margin:0;border:0;padding:0",k.style.marginRight=k.style.width="0",j.style.width="1px",g=!parseFloat((a.getComputedStyle(k)||{}).marginRight),j.removeChild(k)),j.style.display="none",f=0===j.getClientRects().length,f&&(j.style.display="",j.innerHTML="
t
",j.childNodes[0].style.borderCollapse="separate",k=j.getElementsByTagName("td"),k[0].style.cssText="margin:0;border:0;padding:0;display:none",(f=0===k[0].offsetHeight)&&(k[0].style.display="",k[1].style.display="none",f=0===k[0].offsetHeight)),m.removeChild(i)}j.style&&(j.style.cssText="float:left;opacity:.5",l.opacity="0.5"===j.style.opacity,l.cssFloat=!!j.style.cssFloat,j.style.backgroundClip="content-box",j.cloneNode(!0).style.backgroundClip="",l.clearCloneStyle="content-box"===j.style.backgroundClip,i=d.createElement("div"),i.style.cssText="border:0;width:8px;height:0;top:0;left:-9999px;padding:0;margin-top:1px;position:absolute",j.innerHTML="",i.appendChild(j),l.boxSizing=""===j.style.boxSizing||""===j.style.MozBoxSizing||""===j.style.WebkitBoxSizing,n.extend(l,{reliableHiddenOffsets:function(){return null==b&&k(),f},boxSizingReliable:function(){return null==b&&k(),e},pixelMarginRight:function(){return null==b&&k(),c},pixelPosition:function(){return null==b&&k(),b},reliableMarginRight:function(){return null==b&&k(),g},reliableMarginLeft:function(){return null==b&&k(),h}}))}();var Qa,Ra,Sa=/^(top|right|bottom|left)$/;a.getComputedStyle?(Qa=function(b){var c=b.ownerDocument.defaultView;return c&&c.opener||(c=a),c.getComputedStyle(b)},Ra=function(a,b,c){var d,e,f,g,h=a.style;return c=c||Qa(a),g=c?c.getPropertyValue(b)||c[b]:void 0,""!==g&&void 0!==g||n.contains(a.ownerDocument,a)||(g=n.style(a,b)),c&&!l.pixelMarginRight()&&Na.test(g)&&Ma.test(b)&&(d=h.width,e=h.minWidth,f=h.maxWidth,h.minWidth=h.maxWidth=h.width=g,g=c.width,h.width=d,h.minWidth=e,h.maxWidth=f),void 0===g?g:g+""}):Pa.currentStyle&&(Qa=function(a){return a.currentStyle},Ra=function(a,b,c){var d,e,f,g,h=a.style;return c=c||Qa(a),g=c?c[b]:void 0,null==g&&h&&h[b]&&(g=h[b]),Na.test(g)&&!Sa.test(b)&&(d=h.left,e=a.runtimeStyle,f=e&&e.left,f&&(e.left=a.currentStyle.left),h.left="fontSize"===b?"1em":g,g=h.pixelLeft+"px",h.left=d,f&&(e.left=f)),void 0===g?g:g+""||"auto"});function Ta(a,b){return{get:function(){return a()?void delete this.get:(this.get=b).apply(this,arguments)}}}var Ua=/alpha\([^)]*\)/i,Va=/opacity\s*=\s*([^)]*)/i,Wa=/^(none|table(?!-c[ea]).+)/,Xa=new RegExp("^("+S+")(.*)$","i"),Ya={position:"absolute",visibility:"hidden",display:"block"},Za={letterSpacing:"0",fontWeight:"400"},$a=["Webkit","O","Moz","ms"],_a=d.createElement("div").style;function ab(a){if(a in _a)return a;var b=a.charAt(0).toUpperCase()+a.slice(1),c=$a.length;while(c--)if((a=$a[c]+b)in _a)return a}function bb(a,b){for(var c,d,e,f=[],g=0,h=a.length;g=1||""===b)&&""===n.trim(f.replace(Ua,""))&&c.removeAttribute&&(c.removeAttribute("filter"),""===b||d&&!d.filter)||(c.filter=Ua.test(f)?f.replace(Ua,e):f+" "+e)}}),n.cssHooks.marginRight=Ta(l.reliableMarginRight,function(a,b){if(b)return Oa(a,{display:"inline-block"},Ra,[a,"marginRight"])}),n.cssHooks.marginLeft=Ta(l.reliableMarginLeft,function(a,b){if(b)return(parseFloat(Ra(a,"marginLeft"))||(n.contains(a.ownerDocument,a)?a.getBoundingClientRect().left-Oa(a,{marginLeft:0},function(){return a.getBoundingClientRect().left}):0))+"px"}),n.each({ margin:"",padding:"",border:"Width"},function(a,b){n.cssHooks[a+b]={expand:function(c){for(var d=0,e={},f="string"==typeof c?c.split(" "):[c];d<4;d++)e[a+U[d]+b]=f[d]||f[d-2]||f[0];return e}},Ma.test(a)||(n.cssHooks[a+b].set=cb)}),n.fn.extend({css:function(a,b){return X(this,function(a,b,c){var d,e,f={},g=0;if(n.isArray(b)){for(d=Qa(a),e=b.length;g1)},show:function(){return bb(this,!0)},hide:function(){return bb(this)},toggle:function(a){return"boolean"==typeof a?a?this.show():this.hide():this.each(function(){V(this)?n(this).show():n(this).hide()})}});function fb(a,b,c,d,e){return new fb.prototype.init(a,b,c,d,e)}n.Tween=fb,fb.prototype={constructor:fb,init:function(a,b,c,d,e,f){this.elem=a,this.prop=c,this.easing=e||n.easing._default,this.options=b,this.start=this.now=this.cur(),this.end=d,this.unit=f||(n.cssNumber[c]?"":"px")},cur:function(){var a=fb.propHooks[this.prop];return a&&a.get?a.get(this):fb.propHooks._default.get(this)},run:function(a){var b,c=fb.propHooks[this.prop];return this.options.duration?this.pos=b=n.easing[this.easing](a,this.options.duration*a,0,1,this.options.duration):this.pos=b=a,this.now=(this.end-this.start)*b+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),c&&c.set?c.set(this):fb.propHooks._default.set(this),this}},fb.prototype.init.prototype=fb.prototype,fb.propHooks={_default:{get:function(a){var b;return 1!==a.elem.nodeType||null!=a.elem[a.prop]&&null==a.elem.style[a.prop]?a.elem[a.prop]:(b=n.css(a.elem,a.prop,""),b&&"auto"!==b?b:0)},set:function(a){n.fx.step[a.prop]?n.fx.step[a.prop](a):1!==a.elem.nodeType||null==a.elem.style[n.cssProps[a.prop]]&&!n.cssHooks[a.prop]?a.elem[a.prop]=a.now:n.style(a.elem,a.prop,a.now+a.unit)}}},fb.propHooks.scrollTop=fb.propHooks.scrollLeft={set:function(a){a.elem.nodeType&&a.elem.parentNode&&(a.elem[a.prop]=a.now)}},n.easing={linear:function(a){return a},swing:function(a){return.5-Math.cos(a*Math.PI)/2},_default:"swing"},n.fx=fb.prototype.init,n.fx.step={};var gb,hb,ib=/^(?:toggle|show|hide)$/,jb=/queueHooks$/;function kb(){return a.setTimeout(function(){gb=void 0}),gb=n.now()}function lb(a,b){var c,d={height:a},e=0;for(b=b?1:0;e<4;e+=2-b)c=U[e],d["margin"+c]=d["padding"+c]=a;return b&&(d.opacity=d.width=a),d}function mb(a,b,c){for(var d,e=(pb.tweeners[b]||[]).concat(pb.tweeners["*"]),f=0,g=e.length;f
a",a=c.getElementsByTagName("a")[0],b.setAttribute("type","checkbox"),c.appendChild(b),a=c.getElementsByTagName("a")[0],a.style.cssText="top:1px",l.getSetAttribute="t"!==c.className,l.style=/top/.test(a.getAttribute("style")),l.hrefNormalized="/a"===a.getAttribute("href"),l.checkOn=!!b.value,l.optSelected=f.selected,l.enctype=!!d.createElement("form").enctype,e.disabled=!0,l.optDisabled=!f.disabled,b=d.createElement("input"),b.setAttribute("value",""),l.input=""===b.getAttribute("value"),b.value="t",b.setAttribute("type","radio"),l.radioValue="t"===b.value}();var qb=/\r/g,rb=/[\x20\t\r\n\f]+/g;n.fn.extend({val:function(a){var b,c,d,e=this[0];{if(arguments.length)return d=n.isFunction(a),this.each(function(c){var e;1===this.nodeType&&(e=d?a.call(this,c,n(this).val()):a,null==e?e="":"number"==typeof e?e+="":n.isArray(e)&&(e=n.map(e,function(a){return null==a?"":a+""})),(b=n.valHooks[this.type]||n.valHooks[this.nodeName.toLowerCase()])&&"set"in b&&void 0!==b.set(this,e,"value")||(this.value=e))});if(e)return(b=n.valHooks[e.type]||n.valHooks[e.nodeName.toLowerCase()])&&"get"in b&&void 0!==(c=b.get(e,"value"))?c:(c=e.value,"string"==typeof c?c.replace(qb,""):null==c?"":c)}}}),n.extend({valHooks:{option:{get:function(a){var b=n.find.attr(a,"value");return null!=b?b:n.trim(n.text(a)).replace(rb," ")}},select:{get:function(a){for(var b,c,d=a.options,e=a.selectedIndex,f="select-one"===a.type||e<0,g=f?null:[],h=f?e+1:d.length,i=e<0?h:f?e:0;i-1)try{d.selected=c=!0}catch(h){d.scrollHeight}else d.selected=!1;return c||(a.selectedIndex=-1),e}}}}),n.each(["radio","checkbox"],function(){n.valHooks[this]={set:function(a,b){if(n.isArray(b))return a.checked=n.inArray(n(a).val(),b)>-1}},l.checkOn||(n.valHooks[this].get=function(a){return null===a.getAttribute("value")?"on":a.value})});var sb,tb,ub=n.expr.attrHandle,vb=/^(?:checked|selected)$/i,wb=l.getSetAttribute,xb=l.input;n.fn.extend({attr:function(a,b){return X(this,n.attr,a,b,arguments.length>1)},removeAttr:function(a){return this.each(function(){n.removeAttr(this,a)})}}),n.extend({attr:function(a,b,c){var d,e,f=a.nodeType;if(3!==f&&8!==f&&2!==f)return void 0===a.getAttribute?n.prop(a,b,c):(1===f&&n.isXMLDoc(a)||(b=b.toLowerCase(),e=n.attrHooks[b]||(n.expr.match.bool.test(b)?tb:sb)),void 0!==c?null===c?void n.removeAttr(a,b):e&&"set"in e&&void 0!==(d=e.set(a,c,b))?d:(a.setAttribute(b,c+""),c):e&&"get"in e&&null!==(d=e.get(a,b))?d:(d=n.find.attr(a,b),null==d?void 0:d))},attrHooks:{type:{set:function(a,b){if(!l.radioValue&&"radio"===b&&n.nodeName(a,"input")){var c=a.value;return a.setAttribute("type",b),c&&(a.value=c),b}}}},removeAttr:function(a,b){var c,d,e=0,f=b&&b.match(F);if(f&&1===a.nodeType)while(c=f[e++])d=n.propFix[c]||c,n.expr.match.bool.test(c)?xb&&wb||!vb.test(c)?a[d]=!1:a[n.camelCase("default-"+c)]=a[d]=!1:n.attr(a,c,""),a.removeAttribute(wb?c:d)}}),tb={set:function(a,b,c){return!1===b?n.removeAttr(a,c):xb&&wb||!vb.test(c)?a.setAttribute(!wb&&n.propFix[c]||c,c):a[n.camelCase("default-"+c)]=a[c]=!0,c}},n.each(n.expr.match.bool.source.match(/\w+/g),function(a,b){var c=ub[b]||n.find.attr;xb&&wb||!vb.test(b)?ub[b]=function(a,b,d){var e,f;return d||(f=ub[b],ub[b]=e,e=null!=c(a,b,d)?b.toLowerCase():null,ub[b]=f),e}:ub[b]=function(a,b,c){if(!c)return a[n.camelCase("default-"+b)]?b.toLowerCase():null}}),xb&&wb||(n.attrHooks.value={set:function(a,b,c){if(!n.nodeName(a,"input"))return sb&&sb.set(a,b,c);a.defaultValue=b}}),wb||(sb={set:function(a,b,c){var d=a.getAttributeNode(c);if(d||a.setAttributeNode(d=a.ownerDocument.createAttribute(c)),d.value=b+="","value"===c||b===a.getAttribute(c))return b}},ub.id=ub.name=ub.coords=function(a,b,c){var d;if(!c)return(d=a.getAttributeNode(b))&&""!==d.value?d.value:null},n.valHooks.button={get:function(a,b){var c=a.getAttributeNode(b);if(c&&c.specified)return c.value},set:sb.set},n.attrHooks.contenteditable={set:function(a,b,c){sb.set(a,""!==b&&b,c)}},n.each(["width","height"],function(a,b){n.attrHooks[b]={set:function(a,c){if(""===c)return a.setAttribute(b,"auto"),c}}})),l.style||(n.attrHooks.style={get:function(a){return a.style.cssText||void 0},set:function(a,b){return a.style.cssText=b+""}});var yb=/^(?:input|select|textarea|button|object)$/i,zb=/^(?:a|area)$/i;n.fn.extend({prop:function(a,b){return X(this,n.prop,a,b,arguments.length>1)},removeProp:function(a){return a=n.propFix[a]||a,this.each(function(){try{this[a]=void 0,delete this[a]}catch(b){}})}}),n.extend({prop:function(a,b,c){var d,e,f=a.nodeType;if(3!==f&&8!==f&&2!==f)return 1===f&&n.isXMLDoc(a)||(b=n.propFix[b]||b,e=n.propHooks[b]),void 0!==c?e&&"set"in e&&void 0!==(d=e.set(a,c,b))?d:a[b]=c:e&&"get"in e&&null!==(d=e.get(a,b))?d:a[b]},propHooks:{tabIndex:{get:function(a){var b=n.find.attr(a,"tabindex");return b?parseInt(b,10):yb.test(a.nodeName)||zb.test(a.nodeName)&&a.href?0:-1}}},propFix:{for:"htmlFor",class:"className"}}),l.hrefNormalized||n.each(["href","src"],function(a,b){n.propHooks[b]={get:function(a){return a.getAttribute(b,4)}}}),l.optSelected||(n.propHooks.selected={get:function(a){var b=a.parentNode;return b&&(b.selectedIndex,b.parentNode&&b.parentNode.selectedIndex),null},set:function(a){var b=a.parentNode;b&&(b.selectedIndex,b.parentNode&&b.parentNode.selectedIndex)}}),n.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){n.propFix[this.toLowerCase()]=this}),l.enctype||(n.propFix.enctype="encoding");var Ab=/[\t\r\n\f]/g;function Bb(a){return n.attr(a,"class")||""}n.fn.extend({addClass:function(a){var b,c,d,e,f,g,h,i=0;if(n.isFunction(a))return this.each(function(b){n(this).addClass(a.call(this,b,Bb(this)))});if("string"==typeof a&&a){b=a.match(F)||[];while(c=this[i++])if(e=Bb(c),d=1===c.nodeType&&(" "+e+" ").replace(Ab," ")){g=0;while(f=b[g++])d.indexOf(" "+f+" ")<0&&(d+=f+" ");h=n.trim(d),e!==h&&n.attr(c,"class",h)}}return this},removeClass:function(a){var b,c,d,e,f,g,h,i=0;if(n.isFunction(a))return this.each(function(b){n(this).removeClass(a.call(this,b,Bb(this)))});if(!arguments.length)return this.attr("class","");if("string"==typeof a&&a){b=a.match(F)||[];while(c=this[i++])if(e=Bb(c),d=1===c.nodeType&&(" "+e+" ").replace(Ab," ")){g=0;while(f=b[g++])while(d.indexOf(" "+f+" ")>-1)d=d.replace(" "+f+" "," ");h=n.trim(d),e!==h&&n.attr(c,"class",h)}}return this},toggleClass:function(a,b){var c=typeof a;return"boolean"==typeof b&&"string"===c?b?this.addClass(a):this.removeClass(a):n.isFunction(a)?this.each(function(c){n(this).toggleClass(a.call(this,c,Bb(this),b),b)}):this.each(function(){var b,d,e,f;if("string"===c){d=0,e=n(this),f=a.match(F)||[];while(b=f[d++])e.hasClass(b)?e.removeClass(b):e.addClass(b)}else void 0!==a&&"boolean"!==c||(b=Bb(this),b&&n._data(this,"__className__",b),n.attr(this,"class",b||!1===a?"":n._data(this,"__className__")||""))})},hasClass:function(a){var b,c,d=0;b=" "+a+" ";while(c=this[d++])if(1===c.nodeType&&(" "+Bb(c)+" ").replace(Ab," ").indexOf(b)>-1)return!0;return!1}}),n.each("blur focus focusin focusout load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup error contextmenu".split(" "),function(a,b){n.fn[b]=function(a,c){return arguments.length>0?this.on(b,null,a,c):this.trigger(b)}}),n.fn.extend({hover:function(a,b){return this.mouseenter(a).mouseleave(b||a)}});var Cb=a.location,Db=n.now(),Eb=/\?/,Fb=/(,)|(\[|{)|(}|])|"(?:[^"\\\r\n]|\\["\\\/bfnrt]|\\u[\da-fA-F]{4})*"\s*:?|true|false|null|-?(?!0\d)\d+(?:\.\d+|)(?:[eE][+-]?\d+|)/g;n.parseJSON=function(b){if(a.JSON&&a.JSON.parse)return a.JSON.parse(b+"");var c,d=null,e=n.trim(b+"");return e&&!n.trim(e.replace(Fb,function(a,b,e,f){return c&&b&&(d=0),0===d?a:(c=e||b,d+=!f-!e,"")}))?Function("return "+e)():n.error("Invalid JSON: "+b)},n.parseXML=function(b){var c,d;if(!b||"string"!=typeof b)return null;try{a.DOMParser?(d=new a.DOMParser,c=d.parseFromString(b,"text/xml")):(c=new a.ActiveXObject("Microsoft.XMLDOM"),c.async="false",c.loadXML(b))}catch(e){c=void 0}return c&&c.documentElement&&!c.getElementsByTagName("parsererror").length||n.error("Invalid XML: "+b),c};var Gb=/#.*$/,Hb=/([?&])_=[^&]*/,Ib=/^(.*?):[ \t]*([^\r\n]*)\r?$/gm,Jb=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,Kb=/^(?:GET|HEAD)$/,Lb=/^\/\//,Mb=/^([\w.+-]+:)(?:\/\/(?:[^\/?#]*@|)([^\/?#:]*)(?::(\d+)|)|)/,Nb={},Ob={},Pb="*/".concat("*"),Qb=Cb.href,Rb=Mb.exec(Qb.toLowerCase())||[];function Sb(a){return function(b,c){"string"!=typeof b&&(c=b,b="*");var d,e=0,f=b.toLowerCase().match(F)||[];if(n.isFunction(c))while(d=f[e++])"+"===d.charAt(0)?(d=d.slice(1)||"*",(a[d]=a[d]||[]).unshift(c)):(a[d]=a[d]||[]).push(c)}}function Tb(a,b,c,d){var e={},f=a===Ob;function g(h){var i;return e[h]=!0,n.each(a[h]||[],function(a,h){var j=h(b,c,d);return"string"!=typeof j||f||e[j]?f?!(i=j):void 0:(b.dataTypes.unshift(j),g(j),!1)}),i}return g(b.dataTypes[0])||!e["*"]&&g("*")}function Ub(a,b){var c,d,e=n.ajaxSettings.flatOptions||{};for(d in b)void 0!==b[d]&&((e[d]?a:c||(c={}))[d]=b[d]);return c&&n.extend(!0,a,c),a}function Vb(a,b,c){var d,e,f,g,h=a.contents,i=a.dataTypes;while("*"===i[0])i.shift(),void 0===e&&(e=a.mimeType||b.getResponseHeader("Content-Type"));if(e)for(g in h)if(h[g]&&h[g].test(e)){i.unshift(g);break}if(i[0]in c)f=i[0];else{for(g in c){if(!i[0]||a.converters[g+" "+i[0]]){f=g;break}d||(d=g)}f=f||d}if(f)return f!==i[0]&&i.unshift(f),c[f]}function Wb(a,b,c,d){var e,f,g,h,i,j={},k=a.dataTypes.slice();if(k[1])for(g in a.converters)j[g.toLowerCase()]=a.converters[g];f=k.shift();while(f)if(a.responseFields[f]&&(c[a.responseFields[f]]=b),!i&&d&&a.dataFilter&&(b=a.dataFilter(b,a.dataType)),i=f,f=k.shift())if("*"===f)f=i;else if("*"!==i&&i!==f){if(!(g=j[i+" "+f]||j["* "+f]))for(e in j)if(h=e.split(" "),h[1]===f&&(g=j[i+" "+h[0]]||j["* "+h[0]])){!0===g?g=j[e]:!0!==j[e]&&(f=h[0],k.unshift(h[1]));break}if(!0!==g)if(g&&a.throws)b=g(b);else try{b=g(b)}catch(l){return{state:"parsererror",error:g?l:"No conversion from "+i+" to "+f}}}return{state:"success",data:b}}n.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:Qb,type:"GET",isLocal:Jb.test(Rb[1]),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":Pb,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/\bxml\b/,html:/\bhtml/,json:/\bjson\b/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":n.parseJSON,"text xml":n.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(a,b){return b?Ub(Ub(a,n.ajaxSettings),b):Ub(n.ajaxSettings,a)},ajaxPrefilter:Sb(Nb),ajaxTransport:Sb(Ob),ajax:function(b,c){"object"==typeof b&&(c=b,b=void 0),c=c||{};var d,e,f,g,h,i,j,k,l=n.ajaxSetup({},c),m=l.context||l,o=l.context&&(m.nodeType||m.jquery)?n(m):n.event,p=n.Deferred(),q=n.Callbacks("once memory"),r=l.statusCode||{},s={},t={},u=0,v="canceled",w={readyState:0,getResponseHeader:function(a){var b;if(2===u){if(!k){k={};while(b=Ib.exec(g))k[b[1].toLowerCase()]=b[2]}b=k[a.toLowerCase()]}return null==b?null:b},getAllResponseHeaders:function(){return 2===u?g:null},setRequestHeader:function(a,b){var c=a.toLowerCase();return u||(a=t[c]=t[c]||a,s[a]=b),this},overrideMimeType:function(a){return u||(l.mimeType=a),this},statusCode:function(a){var b;if(a)if(u<2)for(b in a)r[b]=[r[b],a[b]];else w.always(a[w.status]);return this},abort:function(a){var b=a||v;return j&&j.abort(b),x(0,b),this}};if(p.promise(w).complete=q.add,w.success=w.done,w.error=w.fail,l.url=((b||l.url||Qb)+"").replace(Gb,"").replace(Lb,Rb[1]+"//"),l.type=c.method||c.type||l.method||l.type,l.dataTypes=n.trim(l.dataType||"*").toLowerCase().match(F)||[""],null==l.crossDomain&&(d=Mb.exec(l.url.toLowerCase()),l.crossDomain=!(!d||d[1]===Rb[1]&&d[2]===Rb[2]&&(d[3]||("http:"===d[1]?"80":"443"))===(Rb[3]||("http:"===Rb[1]?"80":"443")))),l.data&&l.processData&&"string"!=typeof l.data&&(l.data=n.param(l.data,l.traditional)),Tb(Nb,l,c,w),2===u)return w;i=n.event&&l.global,i&&0==n.active++&&n.event.trigger("ajaxStart"),l.type=l.type.toUpperCase(),l.hasContent=!Kb.test(l.type),f=l.url,l.hasContent||(l.data&&(f=l.url+=(Eb.test(f)?"&":"?")+l.data,delete l.data),!1===l.cache&&(l.url=Hb.test(f)?f.replace(Hb,"$1_="+Db++):f+(Eb.test(f)?"&":"?")+"_="+Db++)),l.ifModified&&(n.lastModified[f]&&w.setRequestHeader("If-Modified-Since",n.lastModified[f]),n.etag[f]&&w.setRequestHeader("If-None-Match",n.etag[f])),(l.data&&l.hasContent&&!1!==l.contentType||c.contentType)&&w.setRequestHeader("Content-Type",l.contentType),w.setRequestHeader("Accept",l.dataTypes[0]&&l.accepts[l.dataTypes[0]]?l.accepts[l.dataTypes[0]]+("*"!==l.dataTypes[0]?", "+Pb+"; q=0.01":""):l.accepts["*"]);for(e in l.headers)w.setRequestHeader(e,l.headers[e]);if(l.beforeSend&&(!1===l.beforeSend.call(m,w,l)||2===u))return w.abort();v="abort";for(e in{success:1,error:1,complete:1})w[e](l[e]);if(j=Tb(Ob,l,c,w)){if(w.readyState=1,i&&o.trigger("ajaxSend",[w,l]),2===u)return w;l.async&&l.timeout>0&&(h=a.setTimeout(function(){w.abort("timeout")},l.timeout));try{u=1,j.send(s,x)}catch(y){if(!(u<2))throw y;x(-1,y)}}else x(-1,"No Transport");function x(b,c,d,e){var k,s,t,v,x,y=c;2!==u&&(u=2,h&&a.clearTimeout(h),j=void 0,g=e||"",w.readyState=b>0?4:0,k=b>=200&&b<300||304===b,d&&(v=Vb(l,w,d)),v=Wb(l,v,w,k),k?(l.ifModified&&(x=w.getResponseHeader("Last-Modified"),x&&(n.lastModified[f]=x),(x=w.getResponseHeader("etag"))&&(n.etag[f]=x)),204===b||"HEAD"===l.type?y="nocontent":304===b?y="notmodified":(y=v.state,s=v.data,t=v.error,k=!t)):(t=y,!b&&y||(y="error",b<0&&(b=0))),w.status=b,w.statusText=(c||y)+"",k?p.resolveWith(m,[s,y,w]):p.rejectWith(m,[w,y,t]),w.statusCode(r),r=void 0,i&&o.trigger(k?"ajaxSuccess":"ajaxError",[w,l,k?s:t]),q.fireWith(m,[w,y]),i&&(o.trigger("ajaxComplete",[w,l]),--n.active||n.event.trigger("ajaxStop")))}return w},getJSON:function(a,b,c){return n.get(a,b,c,"json")},getScript:function(a,b){return n.get(a,void 0,b,"script")}}),n.each(["get","post"],function(a,b){n[b]=function(a,c,d,e){return n.isFunction(c)&&(e=e||d,d=c,c=void 0),n.ajax(n.extend({url:a,type:b,dataType:e,data:c,success:d},n.isPlainObject(a)&&a))}}),n._evalUrl=function(a){return n.ajax({url:a,type:"GET",dataType:"script",cache:!0,async:!1,global:!1,throws:!0})},n.fn.extend({wrapAll:function(a){if(n.isFunction(a))return this.each(function(b){n(this).wrapAll(a.call(this,b))});if(this[0]){var b=n(a,this[0].ownerDocument).eq(0).clone(!0);this[0].parentNode&&b.insertBefore(this[0]),b.map(function(){var a=this;while(a.firstChild&&1===a.firstChild.nodeType)a=a.firstChild;return a}).append(this)}return this},wrapInner:function(a){return n.isFunction(a)?this.each(function(b){n(this).wrapInner(a.call(this,b))}):this.each(function(){var b=n(this),c=b.contents();c.length?c.wrapAll(a):b.append(a)})},wrap:function(a){var b=n.isFunction(a);return this.each(function(c){n(this).wrapAll(b?a.call(this,c):a)})},unwrap:function(){return this.parent().each(function(){n.nodeName(this,"body")||n(this).replaceWith(this.childNodes)}).end()}});function Xb(a){return a.style&&a.style.display||n.css(a,"display")}function Yb(a){if(!n.contains(a.ownerDocument||d,a))return!0;while(a&&1===a.nodeType){if("none"===Xb(a)||"hidden"===a.type)return!0;a=a.parentNode}return!1}n.expr.filters.hidden=function(a){return l.reliableHiddenOffsets()?a.offsetWidth<=0&&a.offsetHeight<=0&&!a.getClientRects().length:Yb(a)},n.expr.filters.visible=function(a){return!n.expr.filters.hidden(a)};var Zb=/%20/g,$b=/\[\]$/,_b=/\r?\n/g,ac=/^(?:submit|button|image|reset|file)$/i,bc=/^(?:input|select|textarea|keygen)/i;function cc(a,b,c,d){var e;if(n.isArray(b))n.each(b,function(b,e){c||$b.test(a)?d(a,e):cc(a+"["+("object"==typeof e&&null!=e?b:"")+"]",e,c,d)});else if(c||"object"!==n.type(b))d(a,b);else for(e in b)cc(a+"["+e+"]",b[e],c,d)}n.param=function(a,b){var c,d=[],e=function(a,b){b=n.isFunction(b)?b():null==b?"":b,d[d.length]=encodeURIComponent(a)+"="+encodeURIComponent(b)};if(void 0===b&&(b=n.ajaxSettings&&n.ajaxSettings.traditional),n.isArray(a)||a.jquery&&!n.isPlainObject(a))n.each(a,function(){e(this.name,this.value)});else for(c in a)cc(c,a[c],b,e);return d.join("&").replace(Zb,"+")},n.fn.extend({serialize:function(){return n.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var a=n.prop(this,"elements");return a?n.makeArray(a):this}).filter(function(){var a=this.type;return this.name&&!n(this).is(":disabled")&&bc.test(this.nodeName)&&!ac.test(a)&&(this.checked||!Y.test(a))}).map(function(a,b){var c=n(this).val();return null==c?null:n.isArray(c)?n.map(c,function(a){return{name:b.name,value:a.replace(_b,"\r\n")}}):{name:b.name,value:c.replace(_b,"\r\n")}}).get()}}),n.ajaxSettings.xhr=void 0!==a.ActiveXObject?function(){return this.isLocal?hc():d.documentMode>8?gc():/^(get|post|head|put|delete|options)$/i.test(this.type)&&gc()||hc()}:gc;var dc=0,ec={},fc=n.ajaxSettings.xhr();a.attachEvent&&a.attachEvent("onunload",function(){for(var a in ec)ec[a](void 0,!0)}),l.cors=!!fc&&"withCredentials"in fc,(fc=l.ajax=!!fc)&&n.ajaxTransport(function(b){if(!b.crossDomain||l.cors){var c;return{send:function(d,e){var f,g=b.xhr(),h=++dc;if(g.open(b.type,b.url,b.async,b.username,b.password),b.xhrFields)for(f in b.xhrFields)g[f]=b.xhrFields[f];b.mimeType&&g.overrideMimeType&&g.overrideMimeType(b.mimeType),b.crossDomain||d["X-Requested-With"]||(d["X-Requested-With"]="XMLHttpRequest");for(f in d)void 0!==d[f]&&g.setRequestHeader(f,d[f]+"");g.send(b.hasContent&&b.data||null),c=function(a,d){var f,i,j;if(c&&(d||4===g.readyState))if(delete ec[h],c=void 0,g.onreadystatechange=n.noop,d)4!==g.readyState&&g.abort();else{j={},f=g.status,"string"==typeof g.responseText&&(j.text=g.responseText);try{i=g.statusText}catch(k){i=""}f||!b.isLocal||b.crossDomain?1223===f&&(f=204):f=j.text?200:404}j&&e(f,i,j,g.getAllResponseHeaders())},b.async?4===g.readyState?a.setTimeout(c):g.onreadystatechange=ec[h]=c:c()},abort:function(){c&&c(void 0,!0)}}}});function gc(){try{return new a.XMLHttpRequest}catch(b){}}function hc(){try{return new a.ActiveXObject("Microsoft.XMLHTTP")}catch(b){}}n.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/\b(?:java|ecma)script\b/},converters:{"text script":function(a){return n.globalEval(a),a}}}),n.ajaxPrefilter("script",function(a){void 0===a.cache&&(a.cache=!1),a.crossDomain&&(a.type="GET",a.global=!1)}),n.ajaxTransport("script",function(a){if(a.crossDomain){var b,c=d.head||n("head")[0]||d.documentElement;return{send:function(e,f){b=d.createElement("script"),b.async=!0,a.scriptCharset&&(b.charset=a.scriptCharset),b.src=a.url,b.onload=b.onreadystatechange=function(a,c){(c||!b.readyState||/loaded|complete/.test(b.readyState))&&(b.onload=b.onreadystatechange=null,b.parentNode&&b.parentNode.removeChild(b),b=null,c||f(200,"success"))},c.insertBefore(b,c.firstChild)},abort:function(){b&&b.onload(void 0,!0)}}}});var ic=[],jc=/(=)\?(?=&|$)|\?\?/;n.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var a=ic.pop()||n.expando+"_"+Db++;return this[a]=!0,a}}),n.ajaxPrefilter("json jsonp",function(b,c,d){var e,f,g,h=!1!==b.jsonp&&(jc.test(b.url)?"url":"string"==typeof b.data&&0===(b.contentType||"").indexOf("application/x-www-form-urlencoded")&&jc.test(b.data)&&"data");if(h||"jsonp"===b.dataTypes[0])return e=b.jsonpCallback=n.isFunction(b.jsonpCallback)?b.jsonpCallback():b.jsonpCallback,h?b[h]=b[h].replace(jc,"$1"+e):!1!==b.jsonp&&(b.url+=(Eb.test(b.url)?"&":"?")+b.jsonp+"="+e),b.converters["script json"]=function(){return g||n.error(e+" was not called"),g[0]},b.dataTypes[0]="json",f=a[e],a[e]=function(){g=arguments},d.always(function(){void 0===f?n(a).removeProp(e):a[e]=f,b[e]&&(b.jsonpCallback=c.jsonpCallback,ic.push(e)),g&&n.isFunction(f)&&f(g[0]),g=f=void 0}),"script"}),n.parseHTML=function(a,b,c){if(!a||"string"!=typeof a)return null;"boolean"==typeof b&&(c=b,b=!1),b=b||d;var e=x.exec(a),f=!c&&[];return e?[b.createElement(e[1])]:(e=ia([a],b,f),f&&f.length&&n(f).remove(),n.merge([],e.childNodes))};var kc=n.fn.load;n.fn.load=function(a,b,c){if("string"!=typeof a&&kc)return kc.apply(this,arguments);var d,e,f,g=this,h=a.indexOf(" ");return h>-1&&(d=n.trim(a.slice(h,a.length)),a=a.slice(0,h)),n.isFunction(b)?(c=b,b=void 0):b&&"object"==typeof b&&(e="POST"),g.length>0&&n.ajax({url:a,type:e||"GET",dataType:"html",data:b}).done(function(a){f=arguments,g.html(d?n("
").append(n.parseHTML(a)).find(d):a)}).always(c&&function(a,b){g.each(function(){c.apply(this,f||[a.responseText,b,a])})}),this},n.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(a,b){n.fn[b]=function(a){return this.on(b,a)}}),n.expr.filters.animated=function(a){return n.grep(n.timers,function(b){return a===b.elem}).length};function lc(a){return n.isWindow(a)?a:9===a.nodeType&&(a.defaultView||a.parentWindow)}n.offset={setOffset:function(a,b,c){var d,e,f,g,h,i,j,k=n.css(a,"position"),l=n(a),m={};"static"===k&&(a.style.position="relative"),h=l.offset(),f=n.css(a,"top"),i=n.css(a,"left"),j=("absolute"===k||"fixed"===k)&&n.inArray("auto",[f,i])>-1,j?(d=l.position(),g=d.top,e=d.left):(g=parseFloat(f)||0,e=parseFloat(i)||0),n.isFunction(b)&&(b=b.call(a,c,n.extend({},h))),null!=b.top&&(m.top=b.top-h.top+g),null!=b.left&&(m.left=b.left-h.left+e),"using"in b?b.using.call(a,m):l.css(m)}},n.fn.extend({offset:function(a){if(arguments.length)return void 0===a?this:this.each(function(b){n.offset.setOffset(this,a,b)});var b,c,d={top:0,left:0},e=this[0],f=e&&e.ownerDocument;if(f)return b=f.documentElement,n.contains(b,e)?(void 0!==e.getBoundingClientRect&&(d=e.getBoundingClientRect()),c=lc(f),{top:d.top+(c.pageYOffset||b.scrollTop)-(b.clientTop||0),left:d.left+(c.pageXOffset||b.scrollLeft)-(b.clientLeft||0)}):d},position:function(){if(this[0]){var a,b,c={top:0,left:0},d=this[0];return"fixed"===n.css(d,"position")?b=d.getBoundingClientRect():(a=this.offsetParent(),b=this.offset(),n.nodeName(a[0],"html")||(c=a.offset()),c.top+=n.css(a[0],"borderTopWidth",!0),c.left+=n.css(a[0],"borderLeftWidth",!0)),{top:b.top-c.top-n.css(d,"marginTop",!0),left:b.left-c.left-n.css(d,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var a=this.offsetParent;while(a&&!n.nodeName(a,"html")&&"static"===n.css(a,"position"))a=a.offsetParent;return a||Pa})}}),n.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(a,b){var c=/Y/.test(b);n.fn[a]=function(d){return X(this,function(a,d,e){var f=lc(a);if(void 0===e)return f?b in f?f[b]:f.document.documentElement[d]:a[d];f?f.scrollTo(c?n(f).scrollLeft():e,c?e:n(f).scrollTop()):a[d]=e},a,d,arguments.length,null)}}),n.each(["top","left"],function(a,b){n.cssHooks[b]=Ta(l.pixelPosition,function(a,c){if(c)return c=Ra(a,b),Na.test(c)?n(a).position()[b]+"px":c})}),n.each({Height:"height",Width:"width"},function(a,b){n.each({padding:"inner"+a,content:b,"":"outer"+a},function(c,d){n.fn[d]=function(d,e){var f=arguments.length&&(c||"boolean"!=typeof d),g=c||(!0===d||!0===e?"margin":"border") ;return X(this,function(b,c,d){var e;return n.isWindow(b)?b.document.documentElement["client"+a]:9===b.nodeType?(e=b.documentElement,Math.max(b.body["scroll"+a],e["scroll"+a],b.body["offset"+a],e["offset"+a],e["client"+a])):void 0===d?n.css(b,c,g):n.style(b,c,d,g)},b,f?d:void 0,f,null)}})}),n.fn.extend({bind:function(a,b,c){return this.on(a,null,b,c)},unbind:function(a,b){return this.off(a,null,b)},delegate:function(a,b,c,d){return this.on(b,a,c,d)},undelegate:function(a,b,c){return 1===arguments.length?this.off(a,"**"):this.off(b,a||"**",c)}}),n.fn.size=function(){return this.length},n.fn.andSelf=n.fn.addBack,"function"==typeof define&&define.amd&&define("jquery",[],function(){return n});var mc=a.jQuery,nc=a.$;return n.noConflict=function(b){return a.$===n&&(a.$=nc),b&&a.jQuery===n&&(a.jQuery=mc),n},b||(a.jQuery=a.$=n),n}); jQuery.noConflict(); // source --> https://tobet88.tv/wp-includes/js/jquery/jquery-migrate.min.js?ver=1.4.1 /*! jQuery Migrate v1.4.1 | (c) jQuery Foundation and other contributors | jquery.org/license */ "undefined"==typeof jQuery.migrateMute&&(jQuery.migrateMute=!0),function(a,b,c){function d(c){var d=b.console;f[c]||(f[c]=!0,a.migrateWarnings.push(c),d&&d.warn&&!a.migrateMute&&(d.warn("JQMIGRATE: "+c),a.migrateTrace&&d.trace&&d.trace()))}function e(b,c,e,f){if(Object.defineProperty)try{return void Object.defineProperty(b,c,{configurable:!0,enumerable:!0,get:function(){return d(f),e},set:function(a){d(f),e=a}})}catch(g){}a._definePropertyBroken=!0,b[c]=e}a.migrateVersion="1.4.1";var f={};a.migrateWarnings=[],b.console&&b.console.log&&b.console.log("JQMIGRATE: Migrate is installed"+(a.migrateMute?"":" with logging active")+", version "+a.migrateVersion),a.migrateTrace===c&&(a.migrateTrace=!0),a.migrateReset=function(){f={},a.migrateWarnings.length=0},"BackCompat"===document.compatMode&&d("jQuery is not compatible with Quirks Mode");var g=a("",{size:1}).attr("size")&&a.attrFn,h=a.attr,i=a.attrHooks.value&&a.attrHooks.value.get||function(){return null},j=a.attrHooks.value&&a.attrHooks.value.set||function(){return c},k=/^(?:input|button)$/i,l=/^[238]$/,m=/^(?:autofocus|autoplay|async|checked|controls|defer|disabled|hidden|loop|multiple|open|readonly|required|scoped|selected)$/i,n=/^(?:checked|selected)$/i;e(a,"attrFn",g||{},"jQuery.attrFn is deprecated"),a.attr=function(b,e,f,i){var j=e.toLowerCase(),o=b&&b.nodeType;return i&&(h.length<4&&d("jQuery.fn.attr( props, pass ) is deprecated"),b&&!l.test(o)&&(g?e in g:a.isFunction(a.fn[e])))?a(b)[e](f):("type"===e&&f!==c&&k.test(b.nodeName)&&b.parentNode&&d("Can't change the 'type' of an input or button in IE 6/7/8"),!a.attrHooks[j]&&m.test(j)&&(a.attrHooks[j]={get:function(b,d){var e,f=a.prop(b,d);return f===!0||"boolean"!=typeof f&&(e=b.getAttributeNode(d))&&e.nodeValue!==!1?d.toLowerCase():c},set:function(b,c,d){var e;return c===!1?a.removeAttr(b,d):(e=a.propFix[d]||d,e in b&&(b[e]=!0),b.setAttribute(d,d.toLowerCase())),d}},n.test(j)&&d("jQuery.fn.attr('"+j+"') might use property instead of attribute")),h.call(a,b,e,f))},a.attrHooks.value={get:function(a,b){var c=(a.nodeName||"").toLowerCase();return"button"===c?i.apply(this,arguments):("input"!==c&&"option"!==c&&d("jQuery.fn.attr('value') no longer gets properties"),b in a?a.value:null)},set:function(a,b){var c=(a.nodeName||"").toLowerCase();return"button"===c?j.apply(this,arguments):("input"!==c&&"option"!==c&&d("jQuery.fn.attr('value', val) no longer sets properties"),void(a.value=b))}};var o,p,q=a.fn.init,r=a.find,s=a.parseJSON,t=/^\s*)([^>]*)$/;a.fn.init=function(b,e,f){var g,h;return b&&"string"==typeof b&&!a.isPlainObject(e)&&(g=w.exec(a.trim(b)))&&g[0]&&(t.test(b)||d("$(html) HTML strings must start with '<' character"),g[3]&&d("$(html) HTML text after last tag is ignored"),"#"===g[0].charAt(0)&&(d("HTML string cannot start with a '#' character"),a.error("JQMIGRATE: Invalid selector string (XSS)")),e&&e.context&&e.context.nodeType&&(e=e.context),a.parseHTML)?q.call(this,a.parseHTML(g[2],e&&e.ownerDocument||e||document,!0),e,f):(h=q.apply(this,arguments),b&&b.selector!==c?(h.selector=b.selector,h.context=b.context):(h.selector="string"==typeof b?b:"",b&&(h.context=b.nodeType?b:e||document)),h)},a.fn.init.prototype=a.fn,a.find=function(a){var b=Array.prototype.slice.call(arguments);if("string"==typeof a&&u.test(a))try{document.querySelector(a)}catch(c){a=a.replace(v,function(a,b,c,d){return"["+b+c+'"'+d+'"]'});try{document.querySelector(a),d("Attribute selector with '#' must be quoted: "+b[0]),b[0]=a}catch(e){d("Attribute selector with '#' was not fixed: "+b[0])}}return r.apply(this,b)};var x;for(x in r)Object.prototype.hasOwnProperty.call(r,x)&&(a.find[x]=r[x]);a.parseJSON=function(a){return a?s.apply(this,arguments):(d("jQuery.parseJSON requires a valid JSON string"),null)},a.uaMatch=function(a){a=a.toLowerCase();var b=/(chrome)[ \/]([\w.]+)/.exec(a)||/(webkit)[ \/]([\w.]+)/.exec(a)||/(opera)(?:.*version|)[ \/]([\w.]+)/.exec(a)||/(msie) ([\w.]+)/.exec(a)||a.indexOf("compatible")<0&&/(mozilla)(?:.*? rv:([\w.]+)|)/.exec(a)||[];return{browser:b[1]||"",version:b[2]||"0"}},a.browser||(o=a.uaMatch(navigator.userAgent),p={},o.browser&&(p[o.browser]=!0,p.version=o.version),p.chrome?p.webkit=!0:p.webkit&&(p.safari=!0),a.browser=p),e(a,"browser",a.browser,"jQuery.browser is deprecated"),a.boxModel=a.support.boxModel="CSS1Compat"===document.compatMode,e(a,"boxModel",a.boxModel,"jQuery.boxModel is deprecated"),e(a.support,"boxModel",a.support.boxModel,"jQuery.support.boxModel is deprecated"),a.sub=function(){function b(a,c){return new b.fn.init(a,c)}a.extend(!0,b,this),b.superclass=this,b.fn=b.prototype=this(),b.fn.constructor=b,b.sub=this.sub,b.fn.init=function(d,e){var f=a.fn.init.call(this,d,e,c);return f instanceof b?f:b(f)},b.fn.init.prototype=b.fn;var c=b(document);return d("jQuery.sub() is deprecated"),b},a.fn.size=function(){return d("jQuery.fn.size() is deprecated; use the .length property"),this.length};var y=!1;a.swap&&a.each(["height","width","reliableMarginRight"],function(b,c){var d=a.cssHooks[c]&&a.cssHooks[c].get;d&&(a.cssHooks[c].get=function(){var a;return y=!0,a=d.apply(this,arguments),y=!1,a})}),a.swap=function(a,b,c,e){var f,g,h={};y||d("jQuery.swap() is undocumented and deprecated");for(g in b)h[g]=a.style[g],a.style[g]=b[g];f=c.apply(a,e||[]);for(g in b)a.style[g]=h[g];return f},a.ajaxSetup({converters:{"text json":a.parseJSON}});var z=a.fn.data;a.fn.data=function(b){var e,f,g=this[0];return!g||"events"!==b||1!==arguments.length||(e=a.data(g,b),f=a._data(g,b),e!==c&&e!==f||f===c)?z.apply(this,arguments):(d("Use of jQuery.fn.data('events') is deprecated"),f)};var A=/\/(java|ecma)script/i;a.clean||(a.clean=function(b,c,e,f){c=c||document,c=!c.nodeType&&c[0]||c,c=c.ownerDocument||c,d("jQuery.clean() is deprecated");var g,h,i,j,k=[];if(a.merge(k,a.buildFragment(b,c).childNodes),e)for(i=function(a){return!a.type||A.test(a.type)?f?f.push(a.parentNode?a.parentNode.removeChild(a):a):e.appendChild(a):void 0},g=0;null!=(h=k[g]);g++)a.nodeName(h,"script")&&i(h)||(e.appendChild(h),"undefined"!=typeof h.getElementsByTagName&&(j=a.grep(a.merge([],h.getElementsByTagName("script")),i),k.splice.apply(k,[g+1,0].concat(j)),g+=j.length));return k});var B=a.event.add,C=a.event.remove,D=a.event.trigger,E=a.fn.toggle,F=a.fn.live,G=a.fn.die,H=a.fn.load,I="ajaxStart|ajaxStop|ajaxSend|ajaxComplete|ajaxError|ajaxSuccess",J=new RegExp("\\b(?:"+I+")\\b"),K=/(?:^|\s)hover(\.\S+|)\b/,L=function(b){return"string"!=typeof b||a.event.special.hover?b:(K.test(b)&&d("'hover' pseudo-event is deprecated, use 'mouseenter mouseleave'"),b&&b.replace(K,"mouseenter$1 mouseleave$1"))};a.event.props&&"attrChange"!==a.event.props[0]&&a.event.props.unshift("attrChange","attrName","relatedNode","srcElement"),a.event.dispatch&&e(a.event,"handle",a.event.dispatch,"jQuery.event.handle is undocumented and deprecated"),a.event.add=function(a,b,c,e,f){a!==document&&J.test(b)&&d("AJAX events should be attached to document: "+b),B.call(this,a,L(b||""),c,e,f)},a.event.remove=function(a,b,c,d,e){C.call(this,a,L(b)||"",c,d,e)},a.each(["load","unload","error"],function(b,c){a.fn[c]=function(){var a=Array.prototype.slice.call(arguments,0);return"load"===c&&"string"==typeof a[0]?H.apply(this,a):(d("jQuery.fn."+c+"() is deprecated"),a.splice(0,0,c),arguments.length?this.bind.apply(this,a):(this.triggerHandler.apply(this,a),this))}}),a.fn.toggle=function(b,c){if(!a.isFunction(b)||!a.isFunction(c))return E.apply(this,arguments);d("jQuery.fn.toggle(handler, handler...) is deprecated");var e=arguments,f=b.guid||a.guid++,g=0,h=function(c){var d=(a._data(this,"lastToggle"+b.guid)||0)%g;return a._data(this,"lastToggle"+b.guid,d+1),c.preventDefault(),e[d].apply(this,arguments)||!1};for(h.guid=f;g https://tobet88.tv/wp-content/plugins/wp-extra/js/copy.js?ver=5.4.4 window.onload = function() { document.addEventListener("contextmenu", function(e) { e.preventDefault(); }, false); document.addEventListener("keydown", function(e) { //document.onkeydown = function(e) { // "I" key if (e.ctrlKey && e.shiftKey && e.keyCode == 73) { disabledEvent(e); } // "J" key if (e.ctrlKey && e.shiftKey && e.keyCode == 74) { disabledEvent(e); } // "S" key + macOS if (e.keyCode == 83 && (navigator.platform.match("Mac") ? e.metaKey : e.ctrlKey)) { disabledEvent(e); } // "U" key if (e.ctrlKey && e.keyCode == 85) { disabledEvent(e); } // "F12" key if (event.keyCode == 123) { disabledEvent(e); } if(e.ctrlKey && (e.key == "p" || e.charCode == 16 || e.charCode == 112 || e.keyCode == 80) ){ e.cancelBubble = true; e.preventDefault(); e.stopImmediatePropagation(); } }, false); function disabledEvent(e) { if (e.stopPropagation) { e.stopPropagation(); } else if (window.event) { window.event.cancelBubble = true; } e.preventDefault(); return false; } }; function AddOriginalLink(){ var body_element = document.getElementsByTagName('body')[0]; var selection; selection = window.getSelection(); var pagelink = "Source : "+document.location.href+" - WP Extra"; var copytext = pagelink; var newdiv = document.createElement('div'); newdiv.style.position='absolute'; newdiv.style.left='-99999px'; body_element.appendChild(newdiv); newdiv.innerHTML = copytext; selection.selectAllChildren(newdiv); window.setTimeout(function() { body_element.removeChild(newdiv); },0); }; // To disable Original Link document.oncopy = AddOriginalLink; // To disable click right document.addEventListener("contextmenu", function(e){ e.preventDefault(); }, false); // source --> https://tobet88.tv/wp-content/plugins/bradmax-player/assets/js/default_player.js?ver=2.14.95 /* _ _ | | | | | |__ _ __ __ _ __| |_ __ ___ __ ___ __ | '_ \| '__/ _` |/ _` | '_ ` _ \ / _` \ \/ / | |_) | | | (_| | (_| | | | | | | (_| |> < |_.__/|_| \__,_|\__,_|_| |_| |_|\__,_/_/\_\ Video Player www.bradmax.com */ var $jscomp={scope:{}};$jscomp.defineProperty="function"==typeof Object.defineProperties?Object.defineProperty:function(B,ea,U){if(U.get||U.set)throw new TypeError("ES3 does not support getters and setters.");B!=Array.prototype&&B!=Object.prototype&&(B[ea]=U.value)};$jscomp.getGlobal=function(B){return"undefined"!=typeof window&&window===B?B:"undefined"!=typeof global&&null!=global?global:B};$jscomp.global=$jscomp.getGlobal(this); $jscomp.polyfill=function(B,ea,U,K){if(ea){U=$jscomp.global;B=B.split(".");for(K=0;KU&&(U=Math.max(0,x+U));if(null==K||K>x)K=x;K=Number(K);0>K&&(K=Math.max(0,x+K));for(U=Number(U||0);UU;)--K in this?this[--B]=this[K]:delete this[B];return this}},"es6-impl","es3"); $jscomp.polyfill("Reflect.ownKeys",function(B){return B?B:function(B){var U=[],K=Object.getOwnPropertyNames(B);B=Object.getOwnPropertySymbols(B);for(var x=0;xx||1114111=x?U+=String.fromCharCode(x):(x-=65536,U+=String.fromCharCode(x>>>10&1023|55296),U+=String.fromCharCode(x&1023|56320))}return U}},"es6-impl","es3"); $jscomp.polyfill("Number.isInteger",function(B){return B?B:function(B){return Number.isFinite(B)?B===Math.floor(B):!1}},"es6-impl","es3");$jscomp.polyfill("Array.from",function(B){return B?B:function(B,U,K){$jscomp.initSymbolIterator();U=null!=U?U:function(k){return k};var x=[],k=B[Symbol.iterator];if("function"==typeof k)for(B=k.call(B);!(k=B.next()).done;)x.push(U.call(K,k.value));else for(var k=B.length,p=0;p=k}},"es6-impl","es3");$jscomp.polyfill("Array.prototype.entries",function(B){return B?B:function(){return $jscomp.iteratorFromArray(this,function(B,U){return[B,U]})}},"es6-impl","es3"); $jscomp.polyfill("String.prototype.endsWith",function(B){return B?B:function(B,U){var K=$jscomp.checkStringArgs(this,B,"endsWith");B+="";void 0===U&&(U=K.length);for(var x=Math.max(0,Math.min(U|0,K.length)),k=B.length;0=k}},"es6-impl","es3"); (function(B,ea){"object"===typeof exports&&"undefined"!==typeof module?ea(exports):"function"===typeof define&&define.amd?define(["exports"],ea):(B=B||self,ea(B.bradmax={}))})(this,function(B){var ea={};window.bradmax||(window.bradmax={});window.bradmax.jsdependency||(window.bradmax.jsdependency={});if(!window.bradmax.jsdependency.js_a09afed8bb3673fe6880e9550144541a){window.bradmax.jsdependency.js_a09afed8bb3673fe6880e9550144541a=!0;try{var U={};U.exports&&(ea.header=U.exports)}catch(K){console.error(K)}}window.bradmax|| (window.bradmax={});window.bradmax.jsdependency||(window.bradmax.jsdependency={});if(!window.bradmax.jsdependency.js_d493ed25c95ed67446c3f5fe876487b8){window.bradmax.jsdependency.js_d493ed25c95ed67446c3f5fe876487b8=!0;try{U={},function(B,x,k){"undefined"!=typeof B&&function(p,B){"object"==typeof k&&"object"==typeof x?x.exports=B():"function"==typeof define&&define.amd?define([],B):"object"==typeof k?k.Hls=B():p.Hls=B()}(this,function(){return function(k){function p(ca){if(x[ca])return x[ca].exports; var g=x[ca]={i:ca,l:!1,exports:{}};return k[ca].call(g.exports,g,g.exports,p),g.l=!0,g.exports}var x={};return p.m=k,p.c=x,p.d=function(k,g,y){p.o(k,g)||Object.defineProperty(k,g,{enumerable:!0,get:y})},p.r=function(k){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(k,Symbol.toStringTag,{value:"Module"});Object.defineProperty(k,"__esModule",{value:!0})},p.t=function(k,g){if((1&g&&(k=p(k)),8&g)||4&g&&"object"==typeof k&&k&&k.__esModule)return k;var y=Object.create(null);if(p.r(y), Object.defineProperty(y,"default",{enumerable:!0,value:k}),2&g&&"string"!=typeof k)for(var l in k)p.d(y,l,function(g){return k[g]}.bind(null,l));return y},p.n=function(k){var g=k&&k.__esModule?function(){return k["default"]}:function(){return k};return p.d(g,"a",g),g},p.o=function(k,g){return Object.prototype.hasOwnProperty.call(k,g)},p.p="/dist/",p(p.s=19)}([function(k,x,B){var p;B.d(x,"a",function(){return p});(function(g){g.MEDIA_ATTACHING="hlsMediaAttaching";g.MEDIA_ATTACHED="hlsMediaAttached"; g.MEDIA_DETACHING="hlsMediaDetaching";g.MEDIA_DETACHED="hlsMediaDetached";g.BUFFER_RESET="hlsBufferReset";g.BUFFER_CODECS="hlsBufferCodecs";g.BUFFER_CREATED="hlsBufferCreated";g.BUFFER_APPENDING="hlsBufferAppending";g.BUFFER_APPENDED="hlsBufferAppended";g.BUFFER_EOS="hlsBufferEos";g.BUFFER_FLUSHING="hlsBufferFlushing";g.BUFFER_FLUSHED="hlsBufferFlushed";g.MANIFEST_LOADING="hlsManifestLoading";g.MANIFEST_LOADED="hlsManifestLoaded";g.MANIFEST_PARSED="hlsManifestParsed";g.LEVEL_SWITCHING="hlsLevelSwitching"; g.LEVEL_SWITCHED="hlsLevelSwitched";g.LEVEL_LOADING="hlsLevelLoading";g.LEVEL_LOADED="hlsLevelLoaded";g.LEVEL_UPDATED="hlsLevelUpdated";g.LEVEL_PTS_UPDATED="hlsLevelPtsUpdated";g.LEVELS_UPDATED="hlsLevelsUpdated";g.AUDIO_TRACKS_UPDATED="hlsAudioTracksUpdated";g.AUDIO_TRACK_SWITCHING="hlsAudioTrackSwitching";g.AUDIO_TRACK_SWITCHED="hlsAudioTrackSwitched";g.AUDIO_TRACK_LOADING="hlsAudioTrackLoading";g.AUDIO_TRACK_LOADED="hlsAudioTrackLoaded";g.SUBTITLE_TRACKS_UPDATED="hlsSubtitleTracksUpdated";g.SUBTITLE_TRACKS_CLEARED= "hlsSubtitleTracksCleared";g.SUBTITLE_TRACK_SWITCH="hlsSubtitleTrackSwitch";g.SUBTITLE_TRACK_LOADING="hlsSubtitleTrackLoading";g.SUBTITLE_TRACK_LOADED="hlsSubtitleTrackLoaded";g.SUBTITLE_FRAG_PROCESSED="hlsSubtitleFragProcessed";g.CUES_PARSED="hlsCuesParsed";g.NON_NATIVE_TEXT_TRACKS_FOUND="hlsNonNativeTextTracksFound";g.INIT_PTS_FOUND="hlsInitPtsFound";g.FRAG_LOADING="hlsFragLoading";g.FRAG_LOAD_EMERGENCY_ABORTED="hlsFragLoadEmergencyAborted";g.FRAG_LOADED="hlsFragLoaded";g.FRAG_DECRYPTED="hlsFragDecrypted"; g.FRAG_PARSING_INIT_SEGMENT="hlsFragParsingInitSegment";g.FRAG_PARSING_USERDATA="hlsFragParsingUserdata";g.FRAG_PARSING_METADATA="hlsFragParsingMetadata";g.FRAG_PARSED="hlsFragParsed";g.FRAG_BUFFERED="hlsFragBuffered";g.FRAG_CHANGED="hlsFragChanged";g.FPS_DROP="hlsFpsDrop";g.FPS_DROP_LEVEL_CAPPING="hlsFpsDropLevelCapping";g.ERROR="hlsError";g.DESTROYING="hlsDestroying";g.KEY_LOADING="hlsKeyLoading";g.KEY_LOADED="hlsKeyLoaded";g.LIVE_BACK_BUFFER_REACHED="hlsLiveBackBufferReached";g.BACK_BUFFER_REACHED= "hlsBackBufferReached"})(p||(p={}))},function(k,x,B){function p(e){if(self.console&&!0===e||"object"==typeof e){!function(e){for(var d=arguments.length,b=Array(1"):g;c[b]=d})}(e,"debug","log","info","warn","error");try{l.log()}catch(f){l=y}}else l=y}B.d(x,"a",function(){return p});B.d(x,"b",function(){return h});var g=function(){},y={trace:g,debug:g,log:g, warn:g,info:g,error:g},l=y,h=y},function(k,x,B){var p,g;B.d(x,"b",function(){return p});B.d(x,"a",function(){return g});(function(g){g.NETWORK_ERROR="networkError";g.MEDIA_ERROR="mediaError";g.KEY_SYSTEM_ERROR="keySystemError";g.MUX_ERROR="muxError";g.OTHER_ERROR="otherError"})(p||(p={}));(function(g){g.KEY_SYSTEM_NO_KEYS="keySystemNoKeys";g.KEY_SYSTEM_NO_ACCESS="keySystemNoAccess";g.KEY_SYSTEM_NO_SESSION="keySystemNoSession";g.KEY_SYSTEM_LICENSE_REQUEST_FAILED="keySystemLicenseRequestFailed";g.KEY_SYSTEM_NO_INIT_DATA= "keySystemNoInitData";g.MANIFEST_LOAD_ERROR="manifestLoadError";g.MANIFEST_LOAD_TIMEOUT="manifestLoadTimeOut";g.MANIFEST_PARSING_ERROR="manifestParsingError";g.MANIFEST_INCOMPATIBLE_CODECS_ERROR="manifestIncompatibleCodecsError";g.LEVEL_EMPTY_ERROR="levelEmptyError";g.LEVEL_LOAD_ERROR="levelLoadError";g.LEVEL_LOAD_TIMEOUT="levelLoadTimeOut";g.LEVEL_SWITCH_ERROR="levelSwitchError";g.AUDIO_TRACK_LOAD_ERROR="audioTrackLoadError";g.AUDIO_TRACK_LOAD_TIMEOUT="audioTrackLoadTimeOut";g.SUBTITLE_LOAD_ERROR= "subtitleTrackLoadError";g.SUBTITLE_TRACK_LOAD_TIMEOUT="subtitleTrackLoadTimeOut";g.FRAG_LOAD_ERROR="fragLoadError";g.FRAG_LOAD_TIMEOUT="fragLoadTimeOut";g.FRAG_DECRYPT_ERROR="fragDecryptError";g.FRAG_PARSING_ERROR="fragParsingError";g.REMUX_ALLOC_ERROR="remuxAllocError";g.KEY_LOAD_ERROR="keyLoadError";g.KEY_LOAD_TIMEOUT="keyLoadTimeOut";g.BUFFER_ADD_CODEC_ERROR="bufferAddCodecError";g.BUFFER_INCOMPATIBLE_CODECS_ERROR="bufferIncompatibleCodecsError";g.BUFFER_APPEND_ERROR="bufferAppendError";g.BUFFER_APPENDING_ERROR= "bufferAppendingError";g.BUFFER_STALLED_ERROR="bufferStalledError";g.BUFFER_FULL_ERROR="bufferFullError";g.BUFFER_SEEK_OVER_HOLE="bufferSeekOverHole";g.BUFFER_NUDGE_ON_STALL="bufferNudgeOnStall";g.INTERNAL_EXCEPTION="internalException";g.INTERNAL_ABORTED="aborted";g.UNKNOWN="unknown"})(g||(g={}))},function(k,x,B){B.d(x,"a",function(){return p});var p=Number.isFinite||function(g){return"number"==typeof g&&isFinite(g)};Number.MAX_SAFE_INTEGER},function(k,x,B){function p(b,c){b.prototype=Object.create(c.prototype); b.prototype.constructor=b;g(b,c)}function g(b,c){return(g=Object.setPrototypeOf||function(b,c){return b.__proto__=c,b})(b,c)}function y(b,c){for(var d=0;dd;d++)c[d]=b>>8*(15-d)&255;return c},m.setDecryptDataFromLevelKey=function(c, d){var e=c;return"AES-128"===(null==c?void 0:c.method)&&c.uri&&!c.iv&&((e=b.a.fromURI(c.uri)).method=c.method,e.iv=this.createInitializationVector(d),e.keyFormat="identity"),e},m.setElementaryStreamInfo=function(b,c,d,e,n,f){void 0===f&&(f=!1);var m=this.elementaryStreams,g=m[b];g?(g.startPTS=Math.min(g.startPTS,c),g.endPTS=Math.max(g.endPTS,d),g.startDTS=Math.min(g.startDTS,e),g.endDTS=Math.max(g.endDTS,n)):m[b]={startPTS:c,endPTS:d,startDTS:e,endDTS:n,partial:f}},m.clearElementaryStreamInfo=function(){var b= this.elementaryStreams;b[h.AUDIO]=null;b[h.VIDEO]=null;b[h.AUDIOVIDEO]=null},l(f,[{key:"decryptdata",get:function(){if(!this.levelkey&&!this._decryptdata)return null;if(!this._decryptdata&&this.levelkey){var b=this.sn;"number"!=typeof b&&(this.levelkey&&"AES-128"===this.levelkey.method&&!this.levelkey.iv&&d.b.warn('missing IV for initialization segment with method="'+this.levelkey.method+'" - compliance issue'),b=0);this._decryptdata=this.setDecryptDataFromLevelKey(this.levelkey,b)}return this._decryptdata}}, {key:"end",get:function(){return this.start+this.duration}},{key:"endProgramDateTime",get:function(){if(null===this.programDateTime||!Object(e.a)(this.programDateTime))return null;var b=Object(e.a)(this.duration)?this.duration:0;return this.programDateTime+1E3*b}},{key:"encrypted",get:function(){var b;return!(null===(b=this.decryptdata)||void 0===b||!b.keyFormat||!this.decryptdata.uri)}}]),f}(k),n=function(b){function d(d,e,n,f,m){(n=b.call(this,n)||this).fragOffset=0;n.duration=0;n.gap=!1;n.independent= !1;n.relurl=void 0;n.fragment=void 0;n.index=void 0;n.stats=new c.a;n.duration=d.decimalFloatingPoint("DURATION");n.gap=d.bool("GAP");n.independent=d.bool("INDEPENDENT");n.relurl=d.enumeratedString("URI");n.fragment=e;n.index=f;d=d.enumeratedString("BYTERANGE");return d&&n.setByteRange(d,m),m&&(n.fragOffset=m.fragOffset+m.duration),n}return p(d,b),l(d,[{key:"start",get:function(){return this.fragment.start+this.fragOffset}},{key:"end",get:function(){return this.start+this.duration}},{key:"loaded", get:function(){var b=this.elementaryStreams;return!!(b.audio||b.video||b.audiovideo)}}]),d}(k)},function(k,x,B){function p(b,d){"data"in b&&(d+=b.start,b=b.data);var c=b[d]<<24|b[d+1]<<16|b[d+2]<<8|b[d+3];return 0>c?4294967296+c:c}function g(b,d,c){"data"in b&&(d+=b.start,b=b.data);b[d]=c>>24;b[d+1]=c>>16&255;b[d+2]=c>>8&255;b[d+3]=255&c}function y(b,d){var c,e,n,f=[];if(!d.length)return f;"data"in b?(c=b.data,e=b.start,n=b.end):(e=0,n=(c=b).byteLength);for(;eg?65536+g:g;n+=2;for(h=0;h>>31)return console.warn("SIDX has hierarchical references (not supported)"), null;q=p(c,n);n+=4;b.push({referenceSize:w,subsegmentDuration:q,info:{duration:q/f,start:m,end:m+w-1}});m+=w;n+=4}return{earliestPresentationTime:0,timescale:f,version:e,referencesCount:g,references:b,moovEndOffset:d}}function h(b){for(var c=[],d=y(b,["moov","trak"]),e=0;ed.length)return c.remainder=b,c;d=d[d.length-1];return c.valid=Object(n.a)(b,0,d.start-8),c.remainder=Object(n.a)(b,d.start-8),c}function m(b,c){var d=new Uint8Array(b.length+ c.length);return d.set(b),d.set(c,b.length),d}B.d(x,"b",function(){return y});B.d(x,"g",function(){return l});B.d(x,"f",function(){return h});B.d(x,"d",function(){return e});B.d(x,"c",function(){return f});B.d(x,"e",function(){return b});B.d(x,"h",function(){return c});B.d(x,"a",function(){return m});var n=B(8),q=B(4),w=Math.pow(2,32)-1,W=[].push},function(k,x,B){B.d(x,"b",function(){return l});B.d(x,"a",function(){return e});B.d(x,"d",function(){return f});B.d(x,"e",function(){return d});B.d(x,"c", function(){return b});B.d(x,"f",function(){return c});var p,g=function(b,c){return c+10<=b.length&&73===b[c]&&68===b[c+1]&&51===b[c+2]&&255>b[c+3]&&255>b[c+4]&&128>b[c+6]&&128>b[c+7]&&128>b[c+8]&&128>b[c+9]},y=function(b,c){return c+10<=b.length&&51===b[c]&&68===b[c+1]&&73===b[c+2]&&255>b[c+3]&&255>b[c+4]&&128>b[c+6]&&128>b[c+7]&&128>b[c+8]&&128>b[c+9]},l=function(b,c){for(var d=c,e=0;g(b,c);)e+=10,e+=h(b,c+6),y(b,c+10)&&(e+=10),c+=e;if(0l.size)l=void 0;else var Q=c(l.data,!0),k=new Uint8Array(l.data.subarray(Q.length+1)),l={key:l.type,info:Q,data:k.buffer};else"W"===l.type[0]?"WXXX"===l.type?2>l.size?l=void 0:(k=1,Q=c(l.data.subarray(k),!0),k+=Q.length+1,k=c(l.data.subarray(k)),l={key:l.type,info:Q,data:k}):(Q=c(l.data),l={key:l.type,data:Q}):2>l.size?l=void 0: "TXXX"===l.type?(k=1,Q=c(l.data.subarray(k),!0),k+=Q.length+1,k=c(l.data.subarray(k)),l={key:l.type,info:Q,data:k}):(Q=c(l.data.subarray(1)),l={key:l.type,data:Q});l&&e.push(l);d+=m.size+10}y(b,d)&&(d+=10)}return e},c=function(b,c){void 0===c&&(c=!1);var d=(p||void 0===self.TextDecoder||(p=new self.TextDecoder("utf-8")),p);if(d){d=d.decode(b);if(c){var e=d.indexOf("\x00");return-1!==e?d.substring(0,e):d}return d.replace(/\0/g,"")}for(var f,n=b.length,m="",g=0;g>4){case 0:case 1:case 2:case 3:case 4:case 5:case 6:case 7:m+=String.fromCharCode(d);break;case 12:case 13:e=b[g++];m+=String.fromCharCode((31&d)<<6|63&e);break;case 14:e=b[g++],f=b[g++],m+=String.fromCharCode((15&d)<<12|(63&e)<<6|(63&f)<<0)}return m}},function(k,x,B){function p(g,e,f,d){void 0===f&&(f=1);void 0===d&&(d=!1);g=g*e*f;return d?Math.round(g):g}function g(g,e,f,d){return void 0===f&&(f=1),void 0===d&&(d=!1),p(g,e,1/f,d)}function y(g,e){return void 0===e&&(e=!1),p(g,1E3, 1/9E4,e)}function l(g,e){return void 0===e&&(e=1),p(g,9E4,1/e)}B.d(x,"c",function(){return g});B.d(x,"b",function(){return y});B.d(x,"a",function(){return l})},function(k,x,B){function p(g,k,l){return Uint8Array.prototype.slice?g.slice(k,l):new Uint8Array(Array.prototype.slice.call(g,k,l))}B.d(x,"a",function(){return p})},function(k,x,B){function p(b,c){return 255===b[c]&&240==(246&b[c+1])}function g(b,c){return(3&b[c+3])<<11|b[c+4]<<3|(224&b[c+5])>>>5}function y(b,c){if(c+1=b.length)return!1;var e=g(b,c);if(e<=d)return!1;d=c+e;return d===b.length||d+1>>6);var q=(60&d[e+2])>>>2;q>r.length-1?(c.trigger(X.a.ERROR,{type:N.b.MEDIA_ERROR,details:N.a.FRAG_PARSING_ERROR,fatal:!0,reason:"invalid ADTS sampling index:"+q}),c=void 0):c=(m=(1&d[e+2])<<2,m|= (192&d[e+3])>>>6,O.b.log("manifest codec:"+f+", ADTS type:"+n+", samplingIndex:"+q),/firefox/i.test(v)?6<=q?(n=5,h=Array(4),g=q-3):(n=2,h=Array(2),g=q):-1!==v.indexOf("android")?(n=2,h=Array(2),g=q):(n=5,h=Array(4),f&&(-1!==f.indexOf("mp4a.40.29")||-1!==f.indexOf("mp4a.40.5"))||!f&&6<=q?g=q-3:((f&&-1!==f.indexOf("mp4a.40.2")&&(6<=q&&1===m||/vivaldi/i.test(v))||!f&&1===m)&&(n=2,h=Array(2)),g=q)),h[0]=n<<3,h[0]|=(14&q)>>1,h[1]|=(1&q)<<7,h[1]|=m<<3,5===n&&(h[1]|=(14&g)>>1,h[2]=(1&g)<<7,h[2]|=8,h[3]= 0),{config:h,samplerate:r[q],channelCount:m,codec:"mp4a.40."+n,manifestCodec:f});c&&(b.config=c.config,b.samplerate=c.samplerate,b.channelCount=c.channelCount,b.codec=c.codec,b.manifestCodec=c.manifestCodec,O.b.log("parsed codec:"+b.codec+", rate:"+c.samplerate+", channels:"+c.channelCount))}}function h(b,c,d,e,f){var n=9216E4/b.samplerate,m=c.length,h=1&c[d+1]?7:9,v=g(c,d);e=0<(v-=h)&&d+h+v<=m?{headerLength:h,frameLength:v,stamp:e+f*n}:void 0;if(e)return f=e.stamp,v=e.headerLength,e=e.frameLength, c={unit:c.subarray(d+v,d+v+e),pts:f,dts:f},b.samples.push(c),{sample:c,length:e+v}}function e(b,c){return(e=Object.setPrototypeOf||function(b,c){return b.__proto__=c,b})(b,c)}function f(b,c,e,f,n){if(!(e+24>c.length)){var g=d(c,e);if(g&&e+g.frameLength<=c.length)return f+=9E4*g.samplesPerFrame/g.sampleRate*n,c={unit:c.subarray(e,e+g.frameLength),pts:f,dts:f},b.config=[],b.channelCount=g.channelCount,b.samplerate=g.sampleRate,b.samples.push(c),{sample:c,length:g.frameLength}}}function d(b,c){var d= b[c+1]>>3&3,e=b[c+1]>>1&3,f=b[c+2]>>4&15,n=b[c+2]>>2&3;if(1!==d&&0!==f&&15!==f&&3!==n){var g=b[c+3]>>6,f=1E3*C[14*(3===d?3-e:3===e?3:4)+f-1],n=r[3*(3===d?0:2===d?1:2)+n],m=3===g?1:2,h=E[d][e],v=L[e],d=8*h*v,h=Math.floor(h*f/n+(b[c+2]>>1&1))*v;null===t&&(t=(v=(navigator.userAgent||"").match(/Chrome\/(\d+)/i))?parseInt(v[1]):0);return!!t&&87>=t&&2===e&&224E3<=f&&0===g&&(b[c+3]|=128),{sampleRate:n,channelCount:m,frameLength:h,samplesPerFrame:d}}}function b(b,c){return 255===b[c]&&224==(224&b[c+1])&& 0!=(6&b[c+1])}function c(b,c,d,e){return{key:b,frame:!1,pts:c,dts:d,units:[],debug:e,length:0}}function m(b){var c,d,e,f,n,g=0,m=b.data;if(!b||0===b.size)return null;for(;19>m[0].length&&1b.size-6)return null;e=c[7];192&e&&(f=536870912*(14&c[9])+4194304*(255&c[10])+16384*(254&c[11])+128*(255&c[12])+(254&c[13])/2,64&e?54E5r){h-=r;continue}c=c.subarray(h);r-=h;h=0}b.set(c,g);g+=r}return d&&(d-=e+3),{data:b,pts:f,dts:n,len:d}}return null}function n(b,c){if(b.units.length&&b.frame){if(void 0===b.pts){var d= c.samples,e=d.length;if(!e)return void c.dropped++;d=d[e-1];b.pts=d.pts;b.dts=d.dts}c.samples.push(b)}b.debug.length&&O.b.log(b.pts+"/"+b.dts+":"+b.debug)}function q(b,c){var d=b.length;if(0=b[d-1].pts)b.push(c);else for(--d;0<=d;d--){if(c.ptsb?(this.word<<=b,this.bitsAvailable-=b):(b-=this.bitsAvailable, b-=(c=b>>3)>>3,this.bytesAvailable-=c,this.loadWord(),this.word<<=b,this.bitsAvailable-=b)},c.readBits=function(b){var c=Math.min(this.bitsAvailable,b),d=this.word>>>32-c;return 32>>b))return this.word<<=b, this.bitsAvailable-=b,b;return this.loadWord(),b+this.skipLZ()},c.skipUEG=function(){this.skipBits(1+this.skipLZ())},c.skipEG=function(){this.skipBits(1+this.skipLZ())},c.readUEG=function(){var b=this.skipLZ();return this.readBits(b+1)-1},c.readEG=function(){var b=this.readUEG();return 1&b?1+b>>>1:-1*(b>>>1)},c.readBoolean=function(){return 1===this.readBits(1)},c.readUByte=function(){return this.readBits(8)},c.readUShort=function(){return this.readBits(16)},c.readUInt=function(){return this.readBits(32)}, c.skipScalingList=function(b){for(var c=8,d=8,e=0;ed?16:64);G();b=v();if(0===b)v();else if(1===b)for(r(1),w(),w(),b=v(),d=0;d=b.length)return void d();if(!(32>b[c].unit.length)){var e=this.decrypter.isSync();if(this.decryptAacSample(b, c,d,e),!e)break}}},c.getAvcEncryptedData=function(b){for(var c=new Int8Array(16*Math.floor((b.length-48)/160)+16),d=0,e=32;e<=b.length-16;e+=160,d+=16)c.set(b.subarray(e,e+16),d);return c},c.getAvcDecryptedUnit=function(b,c){for(var d=new Uint8Array(c),e=0,f=32;f<=b.length-16;f+=160,e+=16)b.set(d.subarray(e,e+16),f);return b},c.decryptAvcSample=function(b,c,d,e,f,n){var m=w(f.data),g=this.getAvcEncryptedData(m),h=this;this.decryptBuffer(g.buffer,function(g){f.data=h.getAvcDecryptedUnit(m,g);n||h.decryptAvcSamples(b, c,d+1,e)})},c.decryptAvcSamples=function(b,c,d,e){if(b instanceof Uint8Array)throw Error("Cannot decrypt samples of type Uint8Array");for(;;c++,d=0){if(c>=b.length)return void e();for(var f=b[c].units;!(d>=f.length);d++){var n=f[d];if(!(48>=n.data.length||1!==n.type&&5!==n.type)){var m=this.decrypter.isSync();if(this.decryptAvcSample(b,c,d,e,n,m),!m)return}}}},b}(),v={video:1,audio:2,id3:3,text:4};x=function(){function d(b,c,d){this.typeSupported=this.config=this.observer=void 0;this.sampleAes=null; this.pmtParsed=!1;this.videoCodec=this.audioCodec=void 0;this._duration=0;this._initDTS=this._initPTS=this.aacLastPTS=null;this._pmtId=-1;this._txtTrack=this._id3Track=this._audioTrack=this._avcTrack=void 0;this.remainderData=this.avcSample=this.aacOverFlow=null;this.observer=b;this.config=c;this.typeSupported=d}d.probe=function(b){b=d.syncOffset(b);return!(0>b)&&(b&&O.b.warn("MPEG2-TS detected but first sync word found @ offset "+b+", junk ahead ?"),!0)};d.syncOffset=function(b){for(var c=Math.min(1E3, b.length-564),d=0;dt&&!f)return this.remainderData=b,{audioTrack:g,avcTrack:c,id3Track:h,textTrack:this._txtTrack};var xa=Math.max(0,d.syncOffset(b));(t-=(t+xa)%188)>4){if((z=Y+5+b[Y+4])===Y+188)continue}else z=Y+4;switch(C){case v:k&&(q&&(n=m(q))&&this.parseAVCPES(n,!1),q={data:[],size:0});q&&(q.data.push(b.subarray(z,Y+188)),q.size+=Y+188-z);break;case r:k&&(G&&(n=m(G))&&(g.isAAC?this.parseAACPES(n):this.parseMPEGPES(n)),G={data:[],size:0});G&&(G.data.push(b.subarray(z,Y+188)),G.size+=Y+188-z);break;case w:k&&(S&&(n=m(S))&&this.parseID3PES(n),S={data:[],size:0});S&&(S.data.push(b.subarray(z, Y+188)),S.size+=Y+188-z);break;case 0:k&&(z+=b[z]+1);D=this._pmtId=(31&b[z+10])<<8|b[z+11];break;case D:k&&(z+=b[z]+1);var k=b,C=!0===this.typeSupported.mpeg||!0===this.typeSupported.mp3,W=e,M={audio:-1,avc:-1,id3:-1,isAAC:!0},ga=z+3+((15&k[z+1])<<8|k[z+2])-4;for(z+=12+((15&k[z+10])<<8|k[z+11]);zD;D++)Q.push(m.readUByte().toString(16)),3!==D&&5!==D&&7!==D&&9!==D||Q.push("-");G-=16;for(var D=new Uint8Array(G),t=0;tr;r++)Q=m[r].toString(16),2>Q.length&&(Q="0"+Q),l+=Q;g.codec=l}break;case 8:e=!0;g.pps||(g.pps=[d.data]);break;case 9:e=!1;g.audFound=!0;h&&n(h,g);h=f.avcSample=c(!1,b.pts,b.dts,"");break;case 12:e=!1;break;default:e=!1,h&&(h.debug+="unknown NAL "+d.type+" ")}h&&e&&h.units.push(d)});d&&h&&(n(h,g),this.avcSample=null)},e.getLastNalUnit=function(){var b,c,d=this.avcSample;d&&0!==d.units.length||(d=this._avcTrack.samples, d=d[d.length-1]);null!==(b=d)&&void 0!==b&&b.units&&(b=d.units,c=b[b.length-1]);return c},e.parseAVCNALu=function(b){var c,d,e=b.byteLength,f=this._avcTrack,n=f.naluState||0,m=n,g=[],h=0,v=-1,r=0;for(-1===n&&(v=0,r=31&b[0],n=0,h=1);h=ga&&this.observer.emit(X.a.ERROR,X.a.ERROR,{type:N.b.MEDIA_ERROR,details:N.a.FRAG_PARSING_ERROR,fatal:!0,reason:"no demux matching with content found"}), d.executeEnd=oa(),[{remuxResult:{},chunkMeta:b}];d=f.flush(n);return Q(d)?d.then(function(d){return c.flushRemux(g,d,b),g}):(this.flushRemux(g,d,b),g)},c.flushRemux=function(b,c,d){var e=c.audioTrack,f=c.avcTrack,n=c.id3Track;c=c.textTrack;var m=this.currentTransmuxState,g=m.accurateTimeOffset,m=m.timeOffset;O.b.log("[transmuxer.ts]: Flushed fragment "+d.sn+(-1d;d++)c[d]=b.getUint32(4*d);return c},b.initTable=function(){var b=this.sBox,d=this.invSBox,e=this.subMix,f=e[0],g=e[1],h=e[2],e=e[3],l=this.invSubMix,Q=l[0],k=l[1],N=l[2],l=l[3],D=new Uint32Array(256),Y= 0,M=0,u;for(u=0;256>u;u++)D[u]=128>u?u<<1:u<<1^283;for(u=0;256>u;u++){var P=M^M<<1^M<<2^M<<3^M<<4,P=P>>>8^255&P^99;b[Y]=P;d[P]=Y;var T=D[Y],O=D[T],F=D[O],t=257*D[P]^16843008*P;f[Y]=t<<24|t>>>8;g[Y]=t<<16|t>>>16;h[Y]=t<<8|t>>>24;e[Y]=t;t=16843009*F^65537*O^257*T^16843008*Y;Q[P]=t<<24|t>>>8;k[P]=t<<16|t>>>16;N[P]=t<<8|t>>>24;l[P]=t;Y?(Y=T^D[D[D[F^T]]],M^=D[D[M]]):Y=M=1}},b.expandKey=function(b){b=this.uint8ArrayToUint32Array_(b);for(var c=!0,d=0;d>24&255;g[1]=c>>16&255;g[2]=c>>8&255;g[3]=255&c;g.set(b,4);d=0;for(c=8;d>24&255,c>>16&255,c>>8&255,255&c,e>>24,e>>16&255,e>>8&255,255&e,f>>24,f>>16&255,f>>8&255,255&f,85,196,0,0]))},b.mdia=function(c){return b.box(b.types.mdia,b.mdhd(c.timescale,c.duration),b.hdlr(c.type),b.minf(c))},b.mfhd=function(c){return b.box(b.types.mfhd,new Uint8Array([0,0,0,0,c>>24,c>>16&255,c>>8&255,255&c]))},b.minf=function(c){return"audio"=== c.type?b.box(b.types.minf,b.box(b.types.smhd,b.SMHD),b.DINF,b.stbl(c)):b.box(b.types.minf,b.box(b.types.vmhd,b.VMHD),b.DINF,b.stbl(c))},b.moof=function(c,d,e){return b.box(b.types.moof,b.mfhd(c),b.traf(e,d))},b.moov=function(c){for(var d=c.length,e=[];d--;)e[d]=b.trak(c[d]);return b.box.apply(null,[b.types.moov,b.mvhd(c[0].timescale,c[0].duration)].concat(e).concat(b.mvex(c)))},b.mvex=function(c){for(var d=c.length,e=[];d--;)e[d]=b.trex(c[d]);return b.box.apply(null,[b.types.mvex].concat(e))},b.mvhd= function(c,d){d*=c;var e=Math.floor(d/(h+1)),f=Math.floor(d%(h+1)),e=new Uint8Array([1,0,0,0,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,3,c>>24&255,c>>16&255,c>>8&255,255&c,e>>24,e>>16&255,e>>8&255,255&e,f>>24,f>>16&255,f>>8&255,255&f,0,1,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255]);return b.box(b.types.mvhd,e)},b.sdtp=function(c){var d,e=c.samples||[],f=new Uint8Array(4+e.length);for(c=0;c< e.length;c++)d=e[c].flags,f[c+4]=d.dependsOn<<4|d.isDependedOn<<2|d.hasRedundancy;return b.box(b.types.sdtp,f)},b.stbl=function(c){return b.box(b.types.stbl,b.stsd(c),b.box(b.types.stts,b.STTS),b.box(b.types.stsc,b.STSC),b.box(b.types.stsz,b.STSZ),b.box(b.types.stco,b.STCO))},b.avc1=function(c){var d,e,f,g=[],m=[];for(d=0;d>>8&255),g.push(255&f),g=g.concat(Array.prototype.slice.call(e));for(d=0;d>> 8&255),m.push(255&f),m=m.concat(Array.prototype.slice.call(e));d=b.box(b.types.avcC,new Uint8Array([1,g[3],g[4],g[5],255,224|c.sps.length].concat(g).concat([c.pps.length]).concat(m)));e=c.width;f=c.height;g=c.pixelRatio[0];c=c.pixelRatio[1];return b.box(b.types.avc1,new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,e>>8&255,255&e,f>>8&255,255&f,0,72,0,0,0,72,0,0,0,0,0,0,0,1,18,100,97,105,108,121,109,111,116,105,111,110,47,104,108,115,46,106,115,0,0,0,0,0,0,0,0,0,0,0,0,0,0,24,17,17]), d,b.box(b.types.btrt,new Uint8Array([0,28,156,128,0,45,198,192,0,45,198,192])),b.box(b.types.pasp,new Uint8Array([g>>24,g>>16&255,g>>8&255,255&g,c>>24,c>>16&255,c>>8&255,255&c])))},b.esds=function(b){var c=b.config.length;return new Uint8Array([0,0,0,0,3,23+c,0,1,0,4,15+c,64,21,0,0,0,0,0,0,0,0,0,0,0,5].concat([c]).concat(b.config).concat([6,1,2]))},b.mp4a=function(c){var d=c.samplerate;return b.box(b.types.mp4a,new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,c.channelCount,0,16,0,0,0,0,d>>8&255, 255&d,0,0]),b.box(b.types.esds,b.esds(c)))},b.mp3=function(c){var d=c.samplerate;return b.box(b.types[".mp3"],new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,c.channelCount,0,16,0,0,0,0,d>>8&255,255&d,0,0]))},b.stsd=function(c){return"audio"===c.type?c.isAAC||"mp3"!==c.codec?b.box(b.types.stsd,b.STSD,b.mp4a(c)):b.box(b.types.stsd,b.STSD,b.mp3(c)):b.box(b.types.stsd,b.STSD,b.avc1(c))},b.tkhd=function(c){var d=c.id,e=c.duration*c.timescale,f=c.width;c=c.height;var g=Math.floor(e/(h+1)),e=Math.floor(e% (h+1));return b.box(b.types.tkhd,new Uint8Array([1,0,0,7,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,3,d>>24&255,d>>16&255,d>>8&255,255&d,0,0,0,0,g>>24,g>>16&255,g>>8&255,255&g,e>>24,e>>16&255,e>>8&255,255&e,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0,f>>8&255,255&f,0,0,c>>8&255,255&c,0,0]))},b.traf=function(c,d){var e=b.sdtp(c),f=c.id,g=Math.floor(d/(h+1)),m=Math.floor(d%(h+1));return b.box(b.types.traf,b.box(b.types.tfhd,new Uint8Array([0,0,0,0,f>> 24,f>>16&255,f>>8&255,255&f])),b.box(b.types.tfdt,new Uint8Array([1,0,0,0,g>>24,g>>16&255,g>>8&255,255&g,m>>24,m>>16&255,m>>8&255,255&m])),b.trun(c,e.length+16+20+8+16+8+8),e)},b.trak=function(c){return c.duration=c.duration||4294967295,b.box(b.types.trak,b.tkhd(c),b.mdia(c))},b.trex=function(c){c=c.id;return b.box(b.types.trex,new Uint8Array([0,0,0,0,c>>24,c>>16&255,c>>8&255,255&c,0,0,0,1,0,0,0,0,0,0,0,0,0,1,0,1]))},b.trun=function(c,d){var e,f,g,m,n,h=c.samples||[],q=h.length;e=12+16*q;var w=new Uint8Array(e); d+=8+e;w.set([0,0,15,1,q>>>24&255,q>>>16&255,q>>>8&255,255&q,d>>>24&255,d>>>16&255,d>>>8&255,255&d],0);for(e=0;e>>24&255,g>>>16&255,g>>>8&255,255&g,m>>>24&255,m>>>16&255,m>>>8&255,255&m,n.isLeading<<2|n.dependsOn,n.isDependedOn<<6|n.hasRedundancy<<4|n.paddingValue<<1|n.isNonSync,61440&n.degradPrio,15&n.degradPrio,f>>>24&255,f>>>16&255,f>>>8&255,255&f],12+16*e);return b.box(b.types.trun,w)},b.initSegment=function(c){b.types||b.init();c= b.moov(c);var d=new Uint8Array(b.FTYP.byteLength+c.byteLength);return d.set(b.FTYP),d.set(c,b.FTYP.byteLength),d},b}();e.types=void 0;e.HDLR_TYPES=void 0;e.STTS=void 0;e.STSC=void 0;e.STCO=void 0;e.STSZ=void 0;e.VMHD=void 0;e.SMHD=void 0;e.STSD=void 0;e.FTYP=void 0;e.DINF=void 0;var f=B(0),d=B(2),b=B(1),c=B(7),m=null,n=null,q=!1,w=function(){function h(b,c,d,e){if(this.observer=void 0,this.config=void 0,this.typeSupported=void 0,this.ISGenerated=!1,this._initPTS=void 0,this._initDTS=void 0,this.nextAvcDts= null,this.nextAudioPts=null,this.isAudioContiguous=!1,this.isVideoContiguous=!1,this.observer=b,this.config=c,this.typeSupported=d,this.ISGenerated=!1,null===m)m=(b=(navigator.userAgent||"").match(/Chrome\/(\d+)/i))?parseInt(b[1]):0;null===n&&(n=(b=navigator.userAgent.match(/Safari\/(\d+)/i))?parseInt(b[1]):0);q=!!m&&75>m||!!n&&600>n}var w=h.prototype;return w.destroy=function(){},w.resetTimeStamp=function(c){b.b.log("[mp4-remuxer]: initPTS & initDTS reset");this._initPTS=this._initDTS=c},w.resetNextTimestamp= function(){b.b.log("[mp4-remuxer]: reset next timestamp");this.isAudioContiguous=this.isVideoContiguous=!1},w.resetInitSegment=function(){b.b.log("[mp4-remuxer]: ISGenerated flag reset");this.ISGenerated=!1},w.getVideoStartPts=function(c){var d=!1;c=c.reduce(function(b,c){var e=c.pts-b;return-4294967296>e?(d=!0,g(b,c.pts)):0v.pts)G=Math.max(Math.min(G,v.pts- v.dts),-18E3);v.dtsG){if(G<-2*Y)for(b.b.warn("PTS < DTS detected in video samples, offsetting DTS from PTS by "+Object(c.b)(-Y,!0)+" ms"),D=G,G=0;GY)||-1>w)&&(Y?b.b.warn("AVC: "+Object(c.b)(w,!0)+" ms ("+w+"dts) hole between fragments detected, filling it"):b.b.warn("AVC: "+Object(c.b)(-w,!0)+" ms ("+w+"dts) overlapping between fragments detected"),D=r,Y=z[0].pts-w,z[0].dts=D,z[0].pts=Y,b.b.log("Video: First PTS/DTS adjusted: "+Object(c.b)(Y,!0)+"/"+Object(c.b)(D,!0)+", delta: "+Object(c.b)(w,!0)+" ms"));q&&(D=Math.max(0,D));for(Y=w=r=0;YMath.floor(v.maxBufferHole*M)?(0>(k=za-ua)&&(k=ua),b.b.log("[mp4-remuxer]: It is approximately "+za/90+" ms to the next segment; using duration "+k/90+" ms for the last video frame.")):k=ua):k=ua);t.push(new W(G.key,k,h,Math.round(G.pts-G.dts)))}t.length&&m&&70>m&&(l=t[0].flags,l.dependsOn=2,l.isNonSync= 0);this.nextAvcDts=r=Y+k;this.isVideoContiguous=!0;k={data1:e.moof(n.sequenceNumber++,D,p({},n,{samples:t})),data2:X,startPTS:N/M,endPTS:(S+k)/M,startDTS:D/M,endDTS:r/M,type:"video",hasAudio:!1,hasVideo:!0,nb:t.length,dropped:n.dropped};return n.samples=[],n.dropped=0,k},w.remuxAudio=function(c,m,n,h,q){var w,k=c.inputTimeScale,u=k/(c.samplerate?c.samplerate:k),D=c.isAAC?1024:1152,t=D*u,C=this._initPTS,r=!c.isAAC&&this.typeSupported.mpeg,Y=[],z=c.samples,S=r?0:8,G=this.nextAudioPts||-1,v=m*k;if(this.isAudioContiguous= n=n||z.length&&0Math.abs(v-G)||Math.abs(g(z[0].pts-C,v)-G)<20*t),z.forEach(function(b){b.pts=b.dts=g(b.pts-C,v)}),!n||0>G){if(!(z=z.filter(function(b){return 0<=b.pts})).length)return;G=0===q?0:h?Math.max(0,v):z[0].pts}if(c.isAAC){m=this.config.maxAudioFramesDrift;h=0;for(var Q=G;h=m*t&&1E4>X&&void 0!==q)for(X=Math.floor(A/t),Q=N-X*t,b.b.warn("[mp4-remuxer]: Injecting "+X+" audio frame @ "+(Q/k).toFixed(3)+"s due to "+Math.round(1E3*A/k)+" ms gap."),N=0;Nga)A=Math.round((N-G)/t),b.b.log("[mp4-remuxer]: "+ga+" ms hole between AAC samples detected,filling it"),0ga){b.b.log("[mp4-remuxer]: drop overlapping AAC sample, expected/parsed/delta:"+(G/k).toFixed(3)+"s/"+(N/k).toFixed(3)+"s/"+-ga+"ms");m-=X.byteLength;continue}N=G}if(q=N,!(0b[d].endTime)return-1;for(var e=0,f=d;e<=f;){var ia=Math.floor((f+e)/2);if(cb[ia].startTime&&e=c&&g.endTime<=d)e.push(g);else if(g.startTime>d)break}return e}(b.cues,c,d);for(d=0;db.sn?(f=d-b.start,e=b):(f=b.start-d,e=c);e.duration!==f&&(e.duration=f)}else c.sn>b.sn?b.cc===c.cc&&b.minEndPTS?c.start=b.start+(b.minEndPTS-b.start):c.start=b.start+b.duration: c.start=Math.max(b.start-c.duration,0)}function W(b,c,d,e,f,g){0>=e-d&&(V.b.warn("Fragment should have a positive duration",c),e=d+c.duration,g=f+c.duration);var ia=d,m=e,h=c.startPTS,n=c.endPTS;Object(va.a)(h)&&(ia=Math.abs(h-d),Object(va.a)(c.deltaPTS)?c.deltaPTS=Math.max(ia,c.deltaPTS):c.deltaPTS=ia,ia=Math.max(d,h),d=Math.min(d,h),f=Math.min(f,c.startDTS),m=Math.min(e,n),e=Math.max(e,n),g=Math.max(g,c.endDTS));c.duration=e-d;h=d-c.start;c.appendedPTS=e;c.start=c.startPTS=d;c.maxStartPTS=ia;c.startDTS= f;c.endPTS=e;c.minEndPTS=m;c.endDTS=g;d=c.sn;if(!b||db.endSN)return 0;d-=b.startSN;e=b.fragments;e[d]=c;for(c=d;0d||d>=e.length)&&(d=e[d].start)){for(e=c.skippedSegments;ed.startCC||b&&b.cc=(b[b.length-1].endProgramDateTime||0))return null;d=d||0; for(var e=0;ec)return f}return null}function t(b,c,d,e){void 0===d&&(d=0);void 0===e&&(e=0);var f=null;return(b?f=c[b.sn-c[0].sn+1]:0===d&&0===c[0].start&&(f=c[0]),f&&0===C(d,e,f))?f:rd.search(c,C.bind(null,d,e))||f}function C(b,c,d){void 0===b&&(b=0);void 0===c&&(c=0);c=Math.min(c,d.duration+(d.deltaPTS?d.deltaPTS:0));return d.start+d.duration-c<=b?1:d.start-c>b&&d.start?-1:0}function r(b){var c= "function"==typeof Map?new Map:void 0;return(r=function(b){function d(){return E(b,arguments,G(this).constructor)}if(null===b||(e=b,-1===Function.toString.call(e).indexOf("[native code]")))return b;var e;if("function"!=typeof b)throw new TypeError("Super expression must either be null or a function");if(void 0!==c){if(c.has(b))return c.get(b);c.set(b,d)}return d.prototype=Object.create(b.prototype,{constructor:{value:d,enumerable:!1,writable:!0,configurable:!0}}),S(d,b)})(b)}function E(b,c,d){return(E= L()?Reflect.construct:function(b,c,d){var e=[null];e.push.apply(e,c);b=new (Function.bind.apply(b,e));return d&&S(b,d.prototype),b}).apply(null,arguments)}function L(){if("undefined"==typeof Reflect||!Reflect.construct||Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(xc){return!1}}function S(b,c){return(S=Object.setPrototypeOf||function(b,c){return b.__proto__=c,b})(b,c)}function G(b){return(G= Object.setPrototypeOf?Object.getPrototypeOf:function(b){return b.__proto__||Object.getPrototypeOf(b)})(b)}function v(b,c){void 0===c&&(c=null);var d=c||b,e={frag:b,part:c,responseType:"arraybuffer",url:d.url,rangeStart:0,rangeEnd:0},f=d.byteRangeStartOffset,d=d.byteRangeEndOffset;return Object(va.a)(f)&&Object(va.a)(d)&&(e.rangeStart=f,e.rangeEnd=d),e}function ua(b,c){for(var d=0;db.endSN||0Number.MAX_SAFE_INTEGER?1/0:b},c.hexadecimalInteger=function(b){if(this[b]){b=(this[b]||"0x").slice(2);b=(1&b.length?"0":"")+b;for(var c=new Uint8Array(b.length/2),d=0;dNumber.MAX_SAFE_INTEGER?1/0:b},c.decimalFloatingPoint=function(b){return parseFloat(this[b])}, c.optionalFloat=function(b,c){var d=this[b];return d?parseFloat(d):c},c.enumeratedString=function(b){return this[b]},c.bool=function(b){return"YES"===this[b]},c.decimalResolution=function(b){b=Ab.exec(this[b]);if(null!==b)return{width:parseInt(b[1],10),height:parseInt(b[2],10)}},b.parseAttrList=function(b){var c,d={};for(Ta.lastIndex=0;null!==(c=Ta.exec(b));){var e=c[2];0===e.indexOf('"')&&e.lastIndexOf('"')===e.length-1&&(e=e.slice(1,-1));d[c[1]]=e}return d},b}(),Ya={audio:{a3ds:!0,"ac-3":!0,"ac-4":!0, alac:!0,alaw:!0,dra1:!0,"dts+":!0,"dts-":!0,dtsc:!0,dtse:!0,dtsh:!0,"ec-3":!0,enca:!0,g719:!0,g726:!0,m4ae:!0,mha1:!0,mha2:!0,mhm1:!0,mhm2:!0,mlpa:!0,mp4a:!0,"raw ":!0,Opus:!0,samr:!0,sawb:!0,sawp:!0,sevc:!0,sqcp:!0,ssmv:!0,twos:!0,ulaw:!0},video:{avc1:!0,avc2:!0,avc3:!0,avc4:!0,avcp:!0,av01:!0,drac:!0,dvav:!0,dvhe:!0,encv:!0,hev1:!0,hvc1:!0,mjp2:!0,mp4v:!0,mvc1:!0,mvc2:!0,mvc3:!0,mvc4:!0,resv:!0,rv60:!0,s263:!0,svc1:!0,svc2:!0,"vc-1":!0,vp08:!0,vp09:!0},text:{stpp:!0,wvtt:!0}},ea=/#EXT-X-STREAM-INF:([^\r\n]*)(?:[\r\n](?:#[^\r\n]*)?)*([^\r\n]+)|#EXT-X-SESSION-DATA:([^\r\n]*)[\r\n]+/g, qb=/#EXT-X-MEDIA:(.*)/g,bb=new RegExp([/#EXTINF:\s*(\d*(?:\.\d+)?)(?:,(.*)\s+)?/.source,/(?!#) *(\S[\S ]*)/.source,/#EXT-X-BYTERANGE:*(.+)/.source,/#EXT-X-PROGRAM-DATE-TIME:(.+)/.source,/#.*/.source].join("|"),"g"),Ga=new RegExp([/#(EXTM3U)/.source,/#EXT-X-(PLAYLIST-TYPE):(.+)/.source,/#EXT-X-(MEDIA-SEQUENCE): *(\d+)/.source,/#EXT-X-(SKIP):(.+)/.source,/#EXT-X-(TARGETDURATION): *(\d+)/.source,/#EXT-X-(KEY):(.+)/.source,/#EXT-X-(START):(.+)/.source,/#EXT-X-(ENDLIST)/.source,/#EXT-X-(DISCONTINUITY-SEQ)UENCE: *(\d+)/.source, /#EXT-X-(DIS)CONTINUITY/.source,/#EXT-X-(VERSION):(\d+)/.source,/#EXT-X-(MAP):(.+)/.source,/#EXT-X-(SERVER-CONTROL):(.+)/.source,/#EXT-X-(PART-INF):(.+)/.source,/#EXT-X-(GAP)/.source,/#EXT-X-(BITRATE):\s*(\d+)/.source,/#EXT-X-(PART):(.+)/.source,/#EXT-X-(PRELOAD-HINT):(.+)/.source,/#EXT-X-(RENDITION-REPORT):(.+)/.source,/(#)([^:]*):(.*)/.source,/(#)(.*)(?:.*)\r?\n?/.source].join("|")),Ib=/\.(mp4|m4s|m4v|m4a)$/i,Ua,Za,cb=function(){function b(){}return b.findGroup=function(b,c){for(var d=0;d=n-h&&(n=h+.25);for(var v=0;vc.partTarget&& (f+=1)}if(Object(va.a)(g))return new yc(g,Object(va.a)(f)?f:void 0,vb.No)}}},c.loadPlaylist=function(b){},c.shouldLoadTrack=function(b){return this.canLoad&&b&&!!b.url&&(!b.details||b.details.live)},c.playlistLoaded=function(b,c,d){var e=this,f=c.details,g=c.stats,m=g.loading.end?Math.max(0,self.performance.now()-g.loading.end):0;if(f.advancedDateTime=Date.now()-m,f.live||null!=d&&d.live){if(f.reloaded(d),d&&this.log("live playlist "+b+" "+(f.advanced?"REFRESHED "+f.lastPartSn+"-"+f.lastPartIndex: "MISSED")),d&&0d.tuneInGoal)this.warn("CDN Tune-in goal increased from: "+d.tuneInGoal+" to: "+g+" with playlist age: "+f.age),g=0;else{d=Math.floor(g/f.targetduration); if(m+=d,void 0!==h)h+=Math.round(g%f.targetduration/f.partTarget);this.log("CDN Tune-in age: "+f.ageHeader+"s last advanced "+b.toFixed(2)+"s goal: "+g+" skip sn "+d+" to part "+h)}f.tuneInGoal=g}c=this.getDeliveryDirectives(f,c.deliveryDirectives,m,h);return void this.loadPlaylist(c)}d=function(b,c){var d,e=1E3*b.levelTargetDuration,f=e/2,g=b.age,m=0this.hls.config.fragLoadingMaxRetry&&(g=d.frag.level)):g=d.frag.level);break;case aa.a.LEVEL_LOAD_ERROR:case aa.a.LEVEL_LOAD_TIMEOUT:e&& (e.deliveryDirectives&&(m=!1),g=e.level);f=!0;break;case aa.a.REMUX_ALLOC_ERROR:g=d.level,f=!0}void 0!==g&&this.recoverLevel(d,g,f,m)}}},e.recoverLevel=function(b,c,d,e){var f=b.details,g=this._levels[c];if(g.loadError++,d){if(!this.retryLoadingOrFail(b))return void(this.currentLevelIndex=-1);b.levelRetry=!0}e&&(d=g.url.length,1b||b>=d.length){c=0>b;if(this.hls.trigger(H.a.ERROR,{type:aa.b.OTHER_ERROR,details:aa.a.LEVEL_SWITCH_ERROR,level:b,fatal:c,reason:"invalid level idx"}),c)return;b=Math.min(b,d.length-1)}this.clearTimer();var e=this.currentLevelIndex;c=d[e];d=d[b];this.log("switching to level "+ b+" from "+e);this.currentLevelIndex=b;b=X({},d,{level:b,maxBitrate:d.maxBitrate,uri:d.uri,urlId:d.urlId});delete b._urlId;this.hls.trigger(H.a.LEVEL_SWITCHING,b);b=d.details;if(!b||b.live)b=this.switchParams(d.uri,null==c?void 0:c.details),this.loadPlaylist(b)}}},{key:"manualLevel",get:function(){return this.manualLevelIndex},set:function(b){this.manualLevelIndex=b;void 0===this._startLevel&&(this._startLevel=b);-1!==b&&(this.level=b)}},{key:"firstLevel",get:function(){return this._firstLevel},set:function(b){this._firstLevel= b}},{key:"startLevel",get:function(){if(void 0===this._startLevel){var b=this.hls.config.startLevel;return void 0!==b?b:this._firstLevel}return this._startLevel},set:function(b){this._startLevel=b}},{key:"nextLoadLevel",get:function(){return-1!==this.manualLevelIndex?this.manualLevelIndex:this.hls.nextAutoLevel},set:function(b){this.level=b;-1===this.manualLevelIndex&&(this.hls.nextAutoLevel=b)}}],N(c.prototype,d),c}(zc);!function(b){b.NOT_LOADED="NOT_LOADED";b.BACKTRACKED="BACKTRACKED";b.APPENDING= "APPENDING";b.PARTIAL="PARTIAL";b.OK="OK"}(Db||(Db={}));var La=function(){function b(b){this.activeParts=this.activeFragment=null;this.fragments=Object.create(null);this.timeRanges=Object.create(null);this.bufferPadding=.2;this.hls=void 0;this.hls=b;this._registerListeners()}var c=b.prototype;return c._registerListeners=function(){var b=this.hls;b.on(H.a.BUFFER_APPENDED,this.onBufferAppended,this);b.on(H.a.FRAG_BUFFERED,this.onFragBuffered,this);b.on(H.a.FRAG_LOADED,this.onFragLoaded,this)},c._unregisterListeners= function(){var b=this.hls;b.off(H.a.BUFFER_APPENDED,this.onBufferAppended,this);b.off(H.a.FRAG_BUFFERED,this.onFragBuffered,this);b.off(H.a.FRAG_LOADED,this.onFragLoaded,this)},c.destroy=function(){this._unregisterListeners();this.fragments=this.timeRanges=null},c.getAppendedFrag=function(b,c){if(c===Za.MAIN){var d=this.activeFragment,e=this.activeParts;if(!d)return null;if(e)for(var f=e.length;f--;){var g=e[f],m=g?g.end:d.appendedPTS;if(g.start<=b&&void 0!==m&&b<=m)return 9=h&&g<=n){d.time.push({startPTS:Math.max(f,e.start(m)),endPTS:Math.min(c,e.end(m))});break}if(fh)d.partial=!0,d.time.push({startPTS:Math.max(f,e.start(m)),endPTS:Math.min(c,e.end(m))});else if(c<=h)break}return d},c.getPartialFragment=function(b){var c,d,e,f=null,g=0,m=this.bufferPadding,h=this.fragments; return Object.keys(h).forEach(function(n){(n=h[n])&&Y(n)&&(d=n.body.start-m,e=n.body.end+m,b>=d&&b<=e&&(c=Math.min(b-d,e-b),g<=c&&(f=n.body,g=c)))}),f},c.getState=function(b){b=M(b);return(b=this.fragments[b])?b.buffered?Y(b)?Db.PARTIAL:Db.OK:b.backtrack?Db.BACKTRACKED:Db.APPENDING:Db.NOT_LOADED},c.backtrack=function(b,c){var d=M(b),d=this.fragments[d];if(!d||d.backtrack)return null;var e=d.backtrack=c||d.loaded;return d.loaded=null,e},c.getBacktrackData=function(b){var c=M(b);if(c=this.fragments[c]){var d, c=c.backtrack;if(null!=c&&null!==(d=c.payload)&&void 0!==d&&d.byteLength)return c;this.removeFragment(b)}return null},c.isTimeBuffered=function(b,c,d){for(var e,f,g=0;g=e&&c<=f)return!0;if(c<=e)break}return!1},c.onFragLoaded=function(b,c){var d=c.frag,e=c.part;"initSegment"===d.sn||d.bitrateTest||e||(e=M(d),this.fragments[e]={body:d,loaded:c,backtrack:null,buffered:!1,range:Object.create(null)})},c.onBufferAppended= function(b,c){var d=this,e=c.frag,f=c.part,g=c.timeRanges;if(e.type===Za.MAIN)if(this.activeFragment=e,f){var m=this.activeParts;m||(this.activeParts=m=[]);m.push(f)}else this.activeParts=null;this.timeRanges=g;Object.keys(g).forEach(function(b){var c=g[b];if(d.detectEvictedFragments(b,c),!f)for(b=0;b=e.start(f)&&d<=e.end(f))return!0}catch(Ma){}return!1},b.bufferInfo=function(c, d,e){try{if(c){var f,g=b.getBuffered(c);c=[];for(f=0;fm&&(e[g-1].end=b[f].end):e.push(b[f])}else e.push(b[f])}else e=b;var h;b=0;g=f=c;for(m=0;m=n&&cm))return g;e=f-1}}return null}},Gb=Math.pow(2,17),kb=function(){function b(b){this.config=void 0;this.loader=null;this.partLoadTimeout=-1;this.config=b}var c=b.prototype;return c.destroy=function(){this.loader&& (this.loader.destroy(),this.loader=null)},c.abort=function(){this.loader&&this.loader.abort()},c.load=function(b,c){var d=this,e=b.url;if(!e)return Promise.reject(new uc({type:aa.b.NETWORK_ERROR,details:aa.a.FRAG_LOAD_ERROR,fatal:!1,frag:b,networkDetails:null},"Fragment does not have a "+(e?"part list":"url")));this.abort();var f=this.config,g=f.fLoader,m=f.loader;return new Promise(function(e,h){d.loader&&d.loader.destroy();var n=d.loader=b.loader=g?new g(f):new m(f),ia=v(b),r={timeout:f.fragLoadingTimeOut, maxRetry:0,retryDelay:0,maxRetryDelay:f.fragLoadingMaxRetryTimeout,highWaterMark:Gb};b.stats=n.stats;n.load(ia,r,{onSuccess:function(c,f,g,m){d.resetLoader(b,n);e({frag:b,part:null,payload:c.data,networkDetails:m})},onError:function(c,e,f){d.resetLoader(b,n);h(new uc({type:aa.b.NETWORK_ERROR,details:aa.a.FRAG_LOAD_ERROR,fatal:!1,frag:b,response:c,networkDetails:f}))},onAbort:function(c,e,f){d.resetLoader(b,n);h(new uc({type:aa.b.NETWORK_ERROR,details:aa.a.INTERNAL_ABORTED,fatal:!1,frag:b,networkDetails:f}))}, onTimeout:function(c,e,f){d.resetLoader(b,n);h(new uc({type:aa.b.NETWORK_ERROR,details:aa.a.FRAG_LOAD_TIMEOUT,fatal:!1,frag:b,networkDetails:f}))},onProgress:function(d,e,f,g){c&&c({frag:b,part:null,payload:f,networkDetails:g})}})})},c.loadPart=function(b,c,d){var e=this;this.abort();var f=this.config,g=f.fLoader,m=f.loader;return new Promise(function(h,n){e.loader&&e.loader.destroy();var ia=e.loader=b.loader=g?new g(f):new m(f),r=v(b,c),q={timeout:f.fragLoadingTimeOut,maxRetry:0,retryDelay:0,maxRetryDelay:f.fragLoadingMaxRetryTimeout, highWaterMark:Gb};c.stats=ia.stats;ia.load(r,q,{onSuccess:function(f,g,m,n){e.resetLoader(b,ia);e.updateStatsFromPart(b,c);f={frag:b,part:c,payload:f.data,networkDetails:n};d(f);h(f)},onError:function(d,f,g){e.resetLoader(b,ia);n(new uc({type:aa.b.NETWORK_ERROR,details:aa.a.FRAG_LOAD_ERROR,fatal:!1,frag:b,part:c,response:d,networkDetails:g}))},onAbort:function(d,f,g){b.stats.aborted=c.stats.aborted;e.resetLoader(b,ia);n(new uc({type:aa.b.NETWORK_ERROR,details:aa.a.INTERNAL_ABORTED,fatal:!1,frag:b, part:c,networkDetails:g}))},onTimeout:function(d,f,g){e.resetLoader(b,ia);n(new uc({type:aa.b.NETWORK_ERROR,details:aa.a.FRAG_LOAD_TIMEOUT,fatal:!1,frag:b,part:c,networkDetails:g}))}})})},c.updateStatsFromPart=function(b,c){var d=b.stats,e=c.stats,f=e.total;if(d.loaded+=e.loaded,f){var g=Math.round(b.duration/c.duration),f=Math.min(Math.round(d.loaded/f),g);d.total=d.loaded+(g-f)*Math.round(d.loaded/f)}else d.total=Math.max(d.loaded,d.total);d=d.loading;e=e.loading;d.start?d.first+=e.first-e.start: (d.start=e.start,d.first=e.first);d.end=e.end},c.resetLoader=function(b,c){b.loader=null;this.loader===c&&(self.clearTimeout(this.partLoadTimeout),this.loader=null);c.destroy()},b}(),uc=function(b){function c(c){for(var d,e=arguments.length,f=Array(1e)&&(c.loader&&(this.log("seeking outside of buffer while fragment load in progress, cancel fragment load"),c.loader.abort()),this.resetLoadingState()));d&&(this.lastCurrentTime=f);this.loadedmetadata||g.len||(this.nextLoadPosition=this.startPosition=f);this.tick()},e.onMediaEnded=function(){this.startPosition=this.lastCurrentTime=0},e.onKeyLoaded=function(b, c){if("KEY_LOADING"===this.state&&this.levels){this.state="IDLE";var d=this.levels[c.frag.level].details;d&&this.loadFragment(c.frag,d,c.frag.start)}},e.onHandlerDestroying=function(){this.stopLoad();b.prototype.onHandlerDestroying.call(this)},e.onHandlerDestroyed=function(){this.state="STOPPED";this.hls.off(H.a.KEY_LOADED,this.onKeyLoaded,this);this.fragmentLoader&&this.fragmentLoader.destroy();this.decrypter&&this.decrypter.destroy();this.hls=this.log=this.warn=this.decrypter=this.fragmentLoader= this.fragmentTracker=null;b.prototype.onHandlerDestroyed.call(this)},e.loadFragment=function(b,c,d){this._loadFragForPlayback(b,c,d)},e._loadFragForPlayback=function(b,c,d){var e=this;this._doFragLoad(b,c,d,function(c){if(e.fragContextChanged(b))return e.warn("Fragment "+b.sn+(c.part?" p: "+c.part.index:"")+" of level "+b.level+" was dropped during download."),void e.fragmentTracker.removeFragment(b);b.stats.chunkCount++;e._handleFragmentLoadProgress(c)}).then(function(c){if(c){e.fragLoadError=0; var d=e.state;if(!e.fragContextChanged(b))return"payload"in c&&(e.log("Loaded fragment "+b.sn+" of level "+b.level),e.hls.trigger(H.a.FRAG_LOADED,c),"BACKTRACKING"===e.state)?(e.fragmentTracker.backtrack(b,c),void e.resetFragmentLoading(b)):void e._handleFragmentLoadComplete(c);("FRAG_LOADING"===d||"BACKTRACKING"===d||!e.fragCurrent&&"PARSING"===d)&&(e.fragmentTracker.removeFragment(b),e.state="IDLE")}})["catch"](function(c){e.warn(c);e.resetFragmentLoading(b)})},e.flushMainBuffer=function(b,c,d){void 0=== d&&(d=null);b={startOffset:b,endOffset:c,type:d};this.fragLoadError=0;this.hls.trigger(H.a.BUFFER_FLUSHING,b)},e._loadInitSegment=function(b){var c=this;this._doFragLoad(b).then(function(d){if(!d||c.fragContextChanged(b)||!c.levels)throw Error("init load aborted");return d}).then(function(d){var e=c.hls,f=d.payload,g=b.decryptdata;if(f&&0b.end&&c.fragmentHint&&(b=c.fragmentHint);var m=this.getNextPart(g,b,d);if(-1c&&this.flushMainBuffer(d,b.start)}else this.flushMainBuffer(0, b.start)},e.reduceMaxBufferLength=function(b){var c=this.config;return c.maxMaxBufferLength>=(b||c.maxBufferLength)&&(c.maxMaxBufferLength/=2,this.warn("Reduce max buffer length to "+c.maxMaxBufferLength+"s"),!0)},e.getNextFragment=function(b,c){var d=c.fragments,e=d.length;if(!e)return null;var f,g=this.config,m=d[0].start;if(!c.initSegment||c.initSegment.data||this.bitrateTest)if(c.live){m=g.initialLiveManifestSize;if(ed.start&&d.loaded},e.getInitialLiveFragment=function(b,c){var d=this.fragPrevious,e=null;if(d){if(b.hasProgramDateTime&&(this.log("Live playlist, switching playlist, load frag with same PDT: "+d.programDateTime),e=F(c,d.endProgramDateTime,this.config.maxFragLookUpTolerance)),!e){var f=d.sn+1;f>=b.startSN&&f<=b.endSN&&(f=c[f-b.startSN],d.cc===f.cc&&(e=f,this.log("Live playlist, switching playlist, load frag with next SN: "+e.sn)));e|| (e=function(b,c){return rd.search(b,function(b){return b.ccc?-1:0})}(c,d.cc))&&this.log("Live playlist, switching playlist, load frag with same CC: "+e.sn)}}else d=this.hls.liveSyncPosition,null!==d&&(e=this.getFragmentAtPosition(d,this.bitrateTest?b.fragmentEnd:b.edge,b));return e},e.getFragmentAtPosition=function(b,c,d){var e,f=this.config,g=this.fragPrevious,m=d.fragments,h=d.endSN,n=d.fragmentHint,v=f.maxFragLookUpTolerance,f=!!(f.lowLatencyMode&&d.partList&&n);(f&&n&&!this.bitrateTest&& (m=m.concat(n),h=n.sn),bc-v?0:v):e=m[m.length-1];if(e)if(c=e.sn-d.startSN,d=g&&e.level===g.level,b=m[c+1],this.fragmentTracker.getState(e)===Db.BACKTRACKED){e=null;for(h=c;m[h]&&this.fragmentTracker.getState(m[h])===Db.BACKTRACKED;)e=g?m[h--]:m[--h];e||(e=b)}else g&&e.sn===g.sn&&!f&&d&&(e.sn=b.fragments[0].start-c.maxFragLookUpTolerance&&f<=g;null!==e&&d.duration>e&&(fd.readyState||fMath.max(b.partHoldBack,3*b.partTarget)},e.setStartPosition=function(b,c){var d=this.startPosition;if(-1===this.startPosition||-1===this.lastCurrentTime){var e=b.startTimeOffset;Object(va.a)(e)?(0>e&&(this.log("Negative start time offset "+e+", count from end of last fragment"),e=c+b.totalduration+e),this.log("Start time offset found in playlist, adjust startPosition to "+e),this.startPosition=d=e):b.live?d=this.hls.liveSyncPosition||c:this.startPosition=d=0;this.lastCurrentTime=d}this.nextLoadPosition= d},e.getLoadPosition=function(){var b=this.media,c=0;return this.loadedmetadata?c=b.currentTime:this.nextLoadPosition&&(c=this.nextLoadPosition),c},e.handleFragLoadAborted=function(b,c){this.transmuxer&&"initSegment"!==b.sn&&(this.warn("Fragment "+b.sn+(c?" part"+c.index:"")+" of level "+b.level+" was aborted"),this.resetFragmentLoading(b))},e.resetFragmentLoading=function(b){this.fragCurrent&&this.fragContextChanged(b)||(this.state="IDLE")},e.onFragmentOrKeyLoadError=function(b,c){if(!c.fatal){var d= c.frag;if(d&&d.type===b){this.fragCurrent;var e=this.config;this.fragLoadError+1<=e.fragLoadingMaxRetry?this.resetLiveStartWhenNotLoaded(d.level)||(e=Math.min(Math.pow(2,this.fragLoadError)*e.fragLoadingRetryDelay,e.fragLoadingMaxRetryTimeout),this.warn("Fragment "+d.sn+" of "+b+" "+d.level+" failed to load, retrying in "+e+"ms"),this.retryDate=self.performance.now()+e,this.fragLoadError++,this.state="FRAG_LOADING_WAITING_RETRY"):c.levelRetry?(b===Za.AUDIO&&(this.fragCurrent=null),this.fragLoadError= 0,this.state="IDLE"):(V.b.error(c.details+" reaches max retry, redispatch as fatal ..."),c.fatal=!0,this.hls.stopLoad(),this.state="ERROR")}}},e.afterBufferFlushed=function(b,c){if(b){var d=ub.getBuffered(b);this.fragmentTracker.detectEvictedFragments(c,d);"ENDED"===this.state&&this.resetLoadingState()}},e.resetLoadingState=function(){this.fragPrevious=this.fragCurrent=null;this.state="IDLE"},e.resetLiveStartWhenNotLoaded=function(b){if(!this.loadedmetadata){this.startFragRequested=!1;b=this.levels? this.levels[b].details:null;if(null!=b&&b.live)return this.startPosition=-1,this.setStartPosition(b,0),this.resetLoadingState(),!0;this.nextLoadPosition=this.startPosition}return!1},e.updateLevelTiming=function(b,c,d,e){var f=this,g=d.details;Object.keys(b.elementaryStreams).reduce(function(c,m){var h=b.elementaryStreams[m];if(h){var n=h.endPTS-h.startPTS;if(0>=n)return f.warn("Could not parse fragment "+b.sn+" "+m+" duration reliably ("+n+") resetting transmuxer to fallback to playlist timing"), f.resetTransmuxer(),c||!1;n=e?0:W(g,b,h.startPTS,h.endPTS,h.startDTS,h.endDTS);return f.hls.trigger(H.a.LEVEL_PTS_UPDATED,{details:g,level:d,drift:n,type:m,frag:b,start:h.startPTS,end:h.endPTS}),!0}return c},!1)?(this.state="PARSED",this.hls.trigger(H.a.FRAG_PARSED,{frag:b,part:c})):this.resetLoadingState()},e.resetTransmuxer=function(){this.transmuxer&&(this.transmuxer.destroy(),this.transmuxer=null)},d=[{key:"state",get:function(){return this._state},set:function(b){var c=this._state;c!==b&&(this._state= b,this.log(c+"->"+b))}}],ua(c.prototype,d),c}(gb),Cc=B(17),Hb=B(9),yb=B(13),dd=self.MediaSource||self.WebKitMediaSource||{isTypeSupported:function(){return!1}},pa=function(){function b(b,c,d,e){var f=this;this.observer=this.id=this.hls=void 0;this.part=this.frag=null;this.onwmsg=this.worker=void 0;this.transmuxer=null;this.onFlush=this.onTransmuxComplete=void 0;this.hls=b;this.id=c;this.onTransmuxComplete=d;this.onFlush=e;d=b.config;e=function(c,d){(d=d||{}).frag=f.frag;d.id=f.id;b.trigger(c,d)}; this.observer=new yb.EventEmitter;this.observer.on(H.a.FRAG_DECRYPTED,e);this.observer.on(H.a.ERROR,e);e={mp4:dd.isTypeSupported("video/mp4"),mpeg:dd.isTypeSupported("audio/mpeg"),mp3:dd.isTypeSupported('audio/mp4; codecs="mp3"')};var g=navigator.vendor;if(d.enableWorker&&"undefined"!=typeof Worker){var m;V.b.log("demuxing in webworker");try{m=this.worker=Cc(18),this.onwmsg=this.onWorkerMessage.bind(this),m.addEventListener("message",this.onwmsg),m.onerror=function(c){b.trigger(H.a.ERROR,{type:aa.b.OTHER_ERROR, details:aa.a.INTERNAL_EXCEPTION,fatal:!0,event:"demuxerWorker",error:Error(c.message+" ("+c.filename+":"+c.lineno+")")})},m.postMessage({cmd:"init",typeSupported:e,vendor:g,id:c,config:JSON.stringify(d)})}catch(Jc){V.b.warn("Error in worker:",Jc),V.b.error("Error while initializing DemuxerWorker, fallback to inline"),m&&self.URL.revokeObjectURL(m.objectURL),this.transmuxer=new Hb.c(this.observer,e,d,g),this.worker=null}}else this.transmuxer=new Hb.c(this.observer,e,d,g)}var c=b.prototype;return c.destroy= function(){var b=this.worker;b?(b.removeEventListener("message",this.onwmsg),b.terminate(),this.worker=null):(b=this.transmuxer)&&(b.destroy(),this.transmuxer=null);(b=this.observer)&&b.removeAllListeners();this.observer=null},c.push=function(b,c,d,e,f,g,m,h,n,v){var r=this;n.transmuxing.start=self.performance.now();var q=this.transmuxer,w=this.worker,G=g?g.start:f.start,k=f.decryptdata,ia=this.frag,l=!(ia&&f.cc===ia.cc),S=!(ia&&n.level===ia.level),t=ia?n.sn-ia.sn:-1,u=this.part?n.part-this.part.index: 1,ia=!S&&(1===t||0===t&&1===u),C=self.performance.now();(S||t||0===f.stats.parsing.start)&&(f.stats.parsing.start=C);!g||!u&&ia||(g.stats.parsing.start=C);t=new Hb.b(l,ia,h,S,G);if(!ia||l)V.b.log("[transmuxer-interface, "+f.type+"]: Starting new transmux session for sn: "+n.sn+" p: "+n.part+" level: "+n.level+" id: "+n.id+"\n discontinuity: "+l+"\n trackSwitch: "+S+"\n contiguous: "+ia+"\n accurateTimeOffset: "+h+"\n timeOffset: "+G),c=new Hb.a(d,e,c,m,v),this.configureTransmuxer(c); (this.frag=f,this.part=g,w)?w.postMessage({cmd:"demux",data:b,decryptdata:k,chunkMeta:n,state:t},b instanceof ArrayBuffer?[b]:[]):q&&(b=q.push(b,k,n,t),Object(Hb.d)(b)?b.then(function(b){r.handleTransmuxComplete(b)}):this.handleTransmuxComplete(b))},c.flush=function(b){var c=this;b.transmuxing.start=self.performance.now();var d=this.transmuxer,e=this.worker;e?e.postMessage({cmd:"flush",chunkMeta:b}):d&&(d=d.flush(b),Object(Hb.d)(d)?d.then(function(d){c.handleFlushResult(d,b)}):this.handleFlushResult(d, b))},c.handleFlushResult=function(b,c){var d=this;b.forEach(function(b){d.handleTransmuxComplete(b)});this.onFlush(c)},c.onWorkerMessage=function(b){b=b.data;var c=this.hls;switch(b.event){case "init":self.URL.revokeObjectURL(this.worker.objectURL);break;case "transmuxComplete":this.handleTransmuxComplete(b.data);break;case "flush":this.onFlush(b.data);break;default:b.data=b.data||{},b.data.frag=this.frag,b.data.id=this.id,c.trigger(b.event,b.data)}},c.configureTransmuxer=function(b){var c=this.worker, d=this.transmuxer;c?c.postMessage({cmd:"configure",config:b}):d&&d.configure(b)},c.handleTransmuxComplete=function(b){b.chunkMeta.transmuxing.end=self.performance.now();this.onTransmuxComplete(b)},b}(),rc=function(){function b(b,c,d,e){this.hls=this.fragmentTracker=this.media=this.config=void 0;this.nudgeRetry=0;this.stallReported=!1;this.stalled=null;this.seeking=this.moved=!1;this.config=b;this.media=c;this.fragmentTracker=d;this.hls=e}var c=b.prototype;return c.destroy=function(){this.hls=this.fragmentTracker= this.media=null},c.poll=function(b){var c=this.config,d=this.media,e=this.stalled,f=d.currentTime,g=d.seeking,m=this.seeking&&!g,h=!this.seeking&&g;if(this.seeking=g,f===b){if((h||m)&&(this.stalled=null),!d.paused&&!d.ended&&0!==d.playbackRate&&ub.getBuffered(d).length)if(b=ub.bufferInfo(d,f,0),m=b.nextStart||0,0d.maxBufferHole&&c>1E3*d.highBufferWatchdogPeriod&&(V.b.warn("Trying to nudge playhead over buffer-hole"),this.stalled=null,this._tryNudgeBuffer())},c._reportStall=function(b){var c=this.hls,d=this.media;this.stallReported||(this.stallReported=!0,V.b.warn("Playback stalling at @"+ d.currentTime+" due to low buffer (buffer="+b+")"),c.trigger(H.a.ERROR,{type:aa.b.MEDIA_ERROR,details:aa.a.BUFFER_STALLED_ERROR,fatal:!1,buffer:b}))},c._trySkipBufferHole=function(b){for(var c=this.config,d=this.hls,e=this.media,f=e.currentTime,g=0,m=ub.getBuffered(e),h=0;h=g&&f=d||null!==(c=this.media)&&void 0!==c&&c.seeking)&&(this.log("retryDate reached, switch back to IDLE state"),this.state="IDLE")}this.onTickEnd()},e.onTickEnd=function(){b.prototype.onTickEnd.call(this);this.checkBuffer();this.checkFragmentChanged()},e.doTickIdle=function(){var b,c,d=this.hls,e=this.levels,f=this.media,g=d.config, m=d.nextLoadLevel;if(null!==this.levelLastLoaded&&(f||!this.startFragRequested&&g.startFragPrefetch)&&(!this.altAudio||!this.audioOnly)&&e&&e[m]){var h=e[m];this.level=d.nextLoadLevel=m;d=h.details;if(!d||"WAITING_LEVEL"===this.state||d.live&&this.levelLastLoaded!==m)this.state="WAITING_LEVEL";else{var n=this.getLoadPosition();if(Object(va.a)(n)){var e=d.initSegment,v=0;if(!e||e.data||this.bitrateTest){h=(h=h.maxBitrate)?Math.max(8*g.maxBufferSize/h,g.maxBufferLength):g.maxBufferLength;h=Math.min(h, g.maxMaxBufferLength);f=ub.bufferInfo(this.mediaBuffer?this.mediaBuffer:f,n,n=h)return;if(this._streamEnded(f,d))return b={},this.altAudio&&(b.type="video"),this.hls.trigger(H.a.BUFFER_EOS,b),void(this.state="ENDED");if(v=f.end,(e=this.getNextFragment(v,d))&&this.fragmentTracker.getState(e)===Db.OK&&this.nextLoadPosition>v&&(e=this.getNextFragment(this.nextLoadPosition,d)),!e)return}"identity"!==(null===(b=e.decryptdata)||void 0=== b?void 0:b.keyFormat)||null!==(c=e.decryptdata)&&void 0!==c&&c.key?this.loadFragment(e,d,v):(this.log("Loading key for "+e.sn+" of ["+d.startSN+"-"+d.endSN+"], level "+m),this.loadKey(e))}}}},e.loadKey=function(b){this.state="KEY_LOADING";this.hls.trigger(H.a.KEY_LOADING,{frag:b})},e.loadFragment=function(c,d,e){var f,g=this.fragmentTracker.getState(c);if(this.fragCurrent=c,g===Db.BACKTRACKED){if(g=this.fragmentTracker.getBacktrackData(c))return this._handleFragmentLoadProgress(g),void this._handleFragmentLoadComplete(g); g=Db.NOT_LOADED}g===Db.NOT_LOADED||g===Db.PARTIAL?"initSegment"===c.sn?this._loadInitSegment(c):this.bitrateTest?(c.bitrateTest=!0,this.log("Fragment "+c.sn+" of level "+c.level+" is being downloaded to test bitrate and will not be buffered"),this._loadBitrateTestFrag(c)):(this.startFragRequested=!0,b.prototype.loadFragment.call(this,c,d,e)):g===Db.APPENDING?this.reduceMaxBufferLength(c.duration)&&this.fragmentTracker.removeFragment(c):0===(null===(f=this.media)||void 0===f?void 0:f.buffered.length)&& this.fragmentTracker.removeAllFragments()},e.getAppendedFrag=function(b){return(b=this.fragmentTracker.getAppendedFrag(b,Za.MAIN))&&"fragment"in b?b.fragment:b},e.getBufferedFrag=function(b){return this.fragmentTracker.getBufferedFrag(b,Za.MAIN)},e.followingBufferedFrag=function(b){return b?this.getBufferedFrag(b.end+.5):null},e.immediateLevelSwitch=function(){this.abortCurrentFrag();this.flushMainBuffer(0,Number.POSITIVE_INFINITY)},e.nextLevelSwitch=function(){var b=this.levels,c=this.media;if(null!= c&&c.readyState){var d=this.getAppendedFrag(c.currentTime);(d&&1=this.minWeight_},c.getEstimate=function(){return this.canEstimate()?Math.min(this.fast_.getEstimate(),this.slow_.getEstimate()):this.defaultEstimate_},c.destroy=function(){},b}(),xd=function(){function b(b){this.hls= void 0;this.lastLoadedFragLevel=0;this._nextAutoLevel=-1;this.timer=void 0;this.onCheck=this._abandonRulesCheck.bind(this);this.partCurrent=this.fragCurrent=null;this.bitrateTestDelay=0;this.bwEstimator=void 0;this.hls=b;b=b.config;this.bwEstimator=new Od(b.abrEwmaSlowVoD,b.abrEwmaFastVoD,b.abrEwmaDefaultEstimate);this.registerListeners()}var c,d=b.prototype;return d.registerListeners=function(){var b=this.hls;b.on(H.a.FRAG_LOADING,this.onFragLoading,this);b.on(H.a.FRAG_LOADED,this.onFragLoaded,this); b.on(H.a.FRAG_BUFFERED,this.onFragBuffered,this);b.on(H.a.LEVEL_LOADED,this.onLevelLoaded,this);b.on(H.a.ERROR,this.onError,this)},d.unregisterListeners=function(){var b=this.hls;b.off(H.a.FRAG_LOADING,this.onFragLoading,this);b.off(H.a.FRAG_LOADED,this.onFragLoaded,this);b.off(H.a.FRAG_BUFFERED,this.onFragBuffered,this);b.off(H.a.LEVEL_LOADED,this.onLevelLoaded,this);b.off(H.a.ERROR,this.onError,this)},d.destroy=function(){this.unregisterListeners();this.clearTimer();this.fragCurrent=this.partCurrent= this.hls=this.onCheck=null},d.onFragLoading=function(b,c){var d,e=c.frag;e.type===Za.MAIN&&(this.timer||(this.fragCurrent=e,this.partCurrent=null!=(d=c.part)?d:null,this.timer=self.setInterval(this.onCheck,100)))},d.onLevelLoaded=function(b,c){var d=this.hls.config;c.details.live?this.bwEstimator.update(d.abrEwmaSlowLive,d.abrEwmaFastLive):this.bwEstimator.update(d.abrEwmaSlowVoD,d.abrEwmaFastVoD)},d._abandonRulesCheck=function(){var b=this.fragCurrent,c=this.partCurrent,d=this.hls,e=d.autoLevelEnabled, f=d.config,g=d.media;if(b&&g){var m=c?c.stats:b.stats,h=c?c.duration:b.duration;if(m.aborted)return V.b.warn("frag loader destroy or aborted, disarm abandonRules"),this.clearTimer(),void(this._nextAutoLevel=-1);if(e&&!g.paused&&g.playbackRate&&g.readyState){var e=performance.now()-m.loading.start,n=Math.abs(g.playbackRate);if(!(e<=500*h/n)){var v=d.levels,r=d.minAutoLevel,q=v[b.level],w=Math.max(1,m.bwEstimate?m.bwEstimate/8:1E3*m.loaded/e),q=((m.total||Math.max(m.loaded,Math.round(h*q.maxBitrate/ 8)))-m.loaded)/w,G=g.currentTime,f=(ub.bufferInfo(g,G,f.maxBufferHole).end-G)/n;if(!(f>=2*h/n||q<=f)){n=Number.POSITIVE_INFINITY;for(g=b.level-1;g>r&&!((n=h*v[g].maxBitrate/(6.4*w))=q||(h=this.bwEstimator.getEstimate(),V.b.warn("Fragment "+b.sn+(c?" part "+c.index:"")+" of level "+b.level+" is loading too slowly and will cause an underbuffer; aborting and switching to level "+g+"\n Current BW estimate: "+(Object(va.a)(h)?(h/1024).toFixed(3):"Unknown")+" Kb/s\n Estimated load time for current fragment: "+ q.toFixed(3)+" s\n Estimated load time for the next fragment: "+n.toFixed(3)+" s\n Time to underbuffer: "+f.toFixed(3)+" s"),d.nextLoadLevel=g,this.bwEstimator.sample(e,m.loaded),this.clearTimer(),b.loader&&(this.fragCurrent=this.partCurrent=null,b.loader.abort()),d.trigger(H.a.FRAG_LOAD_EMERGENCY_ABORTED,{frag:b,part:c,stats:m}))}}}}},d.onFragLoaded=function(b,c){var d=c.frag,e=c.part;if(d.type===Za.MAIN&&Object(va.a)(d.sn)){var f=e?e.stats:d.stats,g=e?e.duration:d.duration;if(this.clearTimer(), this.lastLoadedFragLevel=d.level,this._nextAutoLevel=-1,this.hls.config.abrMaxWithRealBitrate){var m=this.hls.levels[d.level],h=(m.loaded?m.loaded.bytes:0)+f.loaded,g=(m.loaded?m.loaded.duration:0)+g;m.loaded={bytes:h,duration:g};m.realBitrate=Math.round(8*h/g)}d.bitrateTest&&(this.onFragBuffered(H.a.FRAG_BUFFERED,{stats:f,frag:d,part:e,id:d.type}),d.bitrateTest=!1)}},d.onFragBuffered=function(b,c){var d=c.frag,e=c.part,e=e?e.stats:d.stats;if(!e.aborted&&d.type===Za.MAIN&&"initSegment"!==d.sn){var f= e.parsing.end-e.loading.start;this.bwEstimator.sample(f,e.loaded);e.bwEstimate=this.bwEstimator.getEstimate();d.bitrateTest?this.bitrateTestDelay=f/1E3:this.bitrateTestDelay=0}},d.onError=function(b,c){switch(c.details){case aa.a.FRAG_LOAD_ERROR:case aa.a.FRAG_LOAD_TIMEOUT:this.clearTimer()}},d.clearTimer=function(){self.clearInterval(this.timer);this.timer=void 0},d.getNextABRAutoLevel=function(){var b=this.fragCurrent,c=this.partCurrent,d=this.hls,e=d.maxAutoLevel,f=d.config,g=d.minAutoLevel,d= d.media,b=c?c.duration:b?b.duration:0,m=d?d.currentTime:0,h=d&&0!==d.playbackRate?Math.abs(d.playbackRate):1,c=this.bwEstimator?this.bwEstimator.getEstimate():f.abrEwmaDefaultEstimate,d=(ub.bufferInfo(d,m,f.maxBufferHole).end-m)/h,m=this.findBestLevel(c,g,e,d,f.abrBandWidthFactor,f.abrBandWidthUpFactor);if(0<=m)return m;V.b.trace((d?"rebuffering expected":"buffer is empty")+", finding optimal quality level");var h=b?Math.min(b,f.maxStarvationDelay):f.maxStarvationDelay,n=f.abrBandWidthFactor,v=f.abrBandWidthUpFactor; if(!d){var r=this.bitrateTestDelay;r&&(h=(b?Math.min(b,f.maxLoadingDelay):f.maxLoadingDelay)-r,V.b.trace("bitrate test took "+Math.round(1E3*r)+"ms, set first fragment max fetchDuration to "+Math.round(1E3*h)+" ms"),n=v=1)}return m=this.findBestLevel(c,g,e,d+h,n,v),Math.max(m,0)},d.findBestLevel=function(b,c,d,e,f,g){var m,h=this.fragCurrent,n=this.partCurrent,v=this.lastLoadedFragLevel,r=this.hls.levels,q=r[v],w=!(null==q||null===(m=q.details)||void 0===m||!m.live);m=null==q?void 0:q.codecSet;for(h= n?n.duration:h?h.duration:0;d>=c;d--)if((q=r[d])&&(!m||q.codecSet===m)){var q=q.details,q=(n?null==q?void 0:q.partTarget:null==q?void 0:q.averagetargetduration)||h,G;G=d<=v?f*b:g*b;var k=r[d].maxBitrate,l=k*q/G;if(V.b.trace("level/adjustedbw/bitrate/avgDuration/maxFetchDuration/fetchDuration: "+d+"/"+Math.round(G)+"/"+k+"/"+q+"/"+e+"/"+l),G>k&&(!l||w&&!this.bitrateTestDelay||l=e||null!==(d=this.media)&&void 0!== d&&d.seeking)&&(this.log("RetryDate reached, switch back to IDLE state"),this.state="IDLE");break;case "WAITING_INIT_PTS":var f=this.waitingData;f?(c=f.frag,d=f.part,e=f.cache,f=f.complete,void 0!==this.initPTS[c.cc]?(this.waitingData=null,this.state="FRAG_LOADING",c={frag:c,part:d,payload:e.flush(),networkDetails:null},this._handleFragmentLoadProgress(c),f&&b.prototype._handleFragmentLoadComplete.call(this,c)):this.videoTrackCC!==this.waitingVideoCC?(V.b.log("Waiting fragment cc ("+c.cc+") cancelled because video is at cc "+ this.videoTrackCC),this.clearWaitingFragment()):(d=ub.bufferInfo(this.mediaBuffer,this.media.currentTime,this.config.maxBufferHole),0>C(d.end,this.config.maxFragLookUpTolerance,c)&&(V.b.log("Waiting fragment cc ("+c.cc+") @ "+c.start+" cancelled because another fragment at "+d.end+" is needed"),this.clearWaitingFragment()))):this.state="IDLE"}this.onTickEnd()},d.clearWaitingFragment=function(){var b=this.waitingData;b&&(this.fragmentTracker.removeFragment(b.frag),this.waitingData=null,this.waitingVideoCC= -1,this.state="IDLE")},d.onTickEnd=function(){var b=this.media;if(b&&b.readyState){var c=(this.mediaBuffer?this.mediaBuffer:b).buffered;!this.loadedmetadata&&c.length&&(this.loadedmetadata=!0);this.lastCurrentTime=b.currentTime}},d.doTickIdle=function(){var b,c,d=this.hls,e=this.levels,f=this.media,g=this.trackId,m=d.config;if(e&&e[g]&&(f||!this.startFragRequested&&m.startFragPrefetch)){var h=this.getLoadPosition();if(Object(va.a)(h))if(e=e[g].details,!e||e.live&&this.levelLastLoaded!==g||this.waitForCdnTuneIn(e))this.state= "WAITING_TRACK";else{var n=e.initSegment,v=0;if(!n||n.data){var r=this.videoBuffer?this.videoBuffer:this.media,q=h=Math.max(Math.min(m.maxBufferLength,m.maxMaxBufferLength),q.len)&&!r)return;if(!r&&this._streamEnded(n,e))return d.trigger(H.a.BUFFER_EOS,{type:"audio"}),void(this.state="ENDED");m=e.fragments[0].start;if(v=n.end, r&&(v=h,e.PTSKnown&&hm||n.nextStart)&&(this.log("Alt audio track ahead of main track, seek to start of alt audio track"),f.currentTime=m+.05)),!(n=this.getNextFragment(v,e)))return}"identity"!==(null===(b=n.decryptdata)||void 0===b?void 0:b.keyFormat)||null!==(c=n.decryptdata)&&void 0!==c&&c.key?this.loadFragment(n,e,v):(this.log("Loading key for "+n.sn+" of ["+e.startSN+" ,"+e.endSN+"],track "+g),this.state="KEY_LOADING",d.trigger(H.a.KEY_LOADING,{frag:n}))}}},d.onMediaDetaching=function(){this.videoBuffer= null;b.prototype.onMediaDetaching.call(this)},d.onAudioTracksUpdated=function(b,c){var d=c.audioTracks;this.resetTransmuxer();this.levels=d.map(function(b){return new tc(b)})},d.onAudioTrackSwitching=function(b,c){var d=!!c.url;this.trackId=c.id;var e=this.fragCurrent;null!=e&&e.loader&&e.loader.abort();this.fragCurrent=null;this.clearWaitingFragment();d?this.setInterval(100):this.resetTransmuxer();d?(this.audioSwitch=!0,this.state="IDLE"):this.state="STOPPED";this.tick()},d.onManifestLoading=function(){this.mainDetails= null;this.fragmentTracker.removeAllFragments();this.startPosition=this.lastCurrentTime=0},d.onLevelLoaded=function(b,c){if(null===this.mainDetails){var d=this.mainDetails=c.details,e=this.levelLastLoaded;null!==e&&this.levels&&-1===this.startPosition&&d.live&&(e=this.levels[e],e.details&&e.details.fragments[0]&&(O(e.details,d),this.setStartPosition(e.details,e.details.fragments[0].start)))}},d.onAudioTrackLoaded=function(b,c){var d,e=this.levels,f=c.details,g=c.id;if(e){this.log("Track "+g+" loaded ["+ f.startSN+","+f.endSN+"],duration:"+f.totalduration);var e=e[g],m=0;if(f.live||null!==(d=e.details)&&void 0!==d&&d.live){var h;if(f.fragments[0]||(f.deltaUpdateFailed=!0),f.deltaUpdateFailed)return;!e.details&&null!==(h=this.mainDetails)&&void 0!==h&&h.hasProgramDateTime&&f.hasProgramDateTime?(O(f,this.mainDetails),m=f.fragments[0].start):m=this.alignPlaylists(f,e.details)}e.details=f;this.levelLastLoaded=g;this.startFragRequested||!this.mainDetails&&f.live||this.setStartPosition(e.details,m);"WAITING_TRACK"!== this.state||this.waitForCdnTuneIn(f)||(this.state="IDLE");this.tick()}else this.warn("Audio tracks were reset while loading level "+g)},d._handleFragmentLoadProgress=function(b){var c,d=b.frag,e=b.part;b=b.payload;var f=this.config,g=this.trackId,m=this.levels;if(m){var h=m[g],m=h.details,f=f.defaultAudioCodec||h.audioCodec||"mp4a.40.2";(h=this.transmuxer)||(h=this.transmuxer=new pa(this.hls,Za.AUDIO,this._handleTransmuxComplete.bind(this),this._handleTransmuxerFlush.bind(this)));var n=this.initPTS[d.cc], v=null===(c=m.initSegment)||void 0===c?void 0:c.data;void 0!==n?(c=e?e.index:-1,c=new vd(d.level,d.sn,d.stats.chunkCount,b.byteLength,c,-1!==c),h.push(b,v,f,"",d,e,m.totalduration,!1,c,n)):(V.b.log("Unknown video PTS for cc "+d.cc+", waiting for video PTS before demuxing audio frag "+d.sn+" of ["+m.startSN+" ,"+m.endSN+"],track "+g),(this.waitingData=this.waitingData||{frag:d,part:e,cache:new yd.a,complete:!1}).cache.push(new Uint8Array(b)),this.waitingVideoCC=this.videoTrackCC,this.state="WAITING_INIT_PTS")}else this.warn("Audio tracks were reset while fragment load was in progress. Fragment "+ d.sn+" of level "+d.level+" will not be buffered")},d._handleFragmentLoadComplete=function(c){this.waitingData?this.waitingData.complete=!0:b.prototype._handleFragmentLoadComplete.call(this,c)},d.onBufferReset=function(){this.mediaBuffer=this.videoBuffer=null;this.loadedmetadata=!1},d.onBufferCreated=function(b,c){var d=c.tracks.audio;d&&(this.mediaBuffer=d.buffer);c.tracks.video&&(this.videoBuffer=c.tracks.video.buffer)},d.onFragBuffered=function(b,c){var d=c.frag,e=c.part;d.type===Za.AUDIO&&(this.fragContextChanged(d)? this.warn("Fragment "+d.sn+(e?" p: "+e.index:"")+" of level "+d.level+" finished buffering, but was aborted. state: "+this.state+", audioSwitch: "+this.audioSwitch):("initSegment"!==d.sn&&(this.fragPrevious=d,this.audioSwitch&&(this.audioSwitch=!1,this.hls.trigger(H.a.AUDIO_TRACK_SWITCHED,{id:this.trackId}))),this.fragBufferedComplete(d,e)))},d.onError=function(c,d){switch(d.details){case aa.a.FRAG_LOAD_ERROR:case aa.a.FRAG_LOAD_TIMEOUT:case aa.a.KEY_LOAD_ERROR:case aa.a.KEY_LOAD_TIMEOUT:this.onFragmentOrKeyLoadError(Za.AUDIO, d);break;case aa.a.AUDIO_TRACK_LOAD_ERROR:case aa.a.AUDIO_TRACK_LOAD_TIMEOUT:"ERROR"!==this.state&&"STOPPED"!==this.state&&(this.state=d.fatal?"ERROR":"IDLE",this.warn(d.details+" while loading frag, switching to "+this.state+" state"));break;case aa.a.BUFFER_FULL_ERROR:if("audio"===d.parent&&("PARSING"===this.state||"PARSED"===this.state)){var e=this.mediaBuffer,f=this.media.currentTime;e&&ub.isBuffered(e,f)&&ub.isBuffered(e,f+.5)?(this.reduceMaxBufferLength(),this.state="IDLE"):(this.warn("Buffer full error also media.currentTime is not buffered, flush audio buffer"), this.fragCurrent=null,b.prototype.flushMainBuffer.call(this,0,Number.POSITIVE_INFINITY,"audio"))}}},d.onBufferFlushed=function(b,c){var d=c.type;d===Ra.a.AUDIO&&this.afterBufferFlushed(this.mediaBuffer?this.mediaBuffer:this.media,d)},d._handleTransmuxComplete=function(b){var c,d=this.hls,e=b.remuxResult,f=b.chunkMeta,g=this.getCurrentContext(f);if(!g)return this.warn("The loading context changed while buffering fragment "+f.sn+" of level "+f.level+". This chunk will not be buffered."),void this.resetLiveStartWhenNotLoaded(f.level); b=g.frag;var m=g.part,h=e.audio,g=e.text,n=e.id3,e=e.initSegment;if(!this.fragContextChanged(b)){if(this.state="PARSING",this.audioSwitch&&h&&this.completeAudioSwitch(),null!=e&&e.tracks&&(this._bufferInitSegment(e.tracks,b,f),d.trigger(H.a.FRAG_PARSING_INIT_SEGMENT,{frag:b,id:"audio",tracks:e.tracks})),h){var e=h.startPTS,v=h.endPTS,r=h.startDTS,q=h.endDTS;m&&(m.elementaryStreams[Ra.a.AUDIO]={startPTS:e,endPTS:v,startDTS:r,endDTS:q});b.setElementaryStreamInfo(Ra.a.AUDIO,e,v,r,q);this.bufferFragmentData(h, b,m,f)}null!=n&&null!==(c=n.samples)&&void 0!==c&&c.length&&(c=ra({frag:b,id:"audio"},n),d.trigger(H.a.FRAG_PARSING_METADATA,c));g&&(c=ra({frag:b,id:"audio"},g),d.trigger(H.a.FRAG_PARSING_USERDATA,c))}},d._bufferInitSegment=function(b,c,d){if("PARSING"===this.state){b.video&&delete b.video;var e=b.audio;e&&(e.levelCodec=e.codec,e.id="audio",this.log("Init audio buffer, container:"+e.container+", codecs[parsed]=["+e.codec+"]"),this.hls.trigger(H.a.BUFFER_CODECS,b),b=e.initSegment,null!=b&&b.byteLength&& this.hls.trigger(H.a.BUFFER_APPENDING,{type:"audio",frag:c,part:null,chunkMeta:d,parent:c.type,data:b}),this.tick())}},d.loadFragment=function(c,d,e){var f=this.fragmentTracker.getState(c);this.fragCurrent=c;(this.audioSwitch||f===Db.NOT_LOADED||f===Db.PARTIAL)&&("initSegment"===c.sn?this._loadInitSegment(c):d.live&&!Object(va.a)(this.initPTS[c.cc])?(this.log("Waiting for video PTS in continuity counter "+c.cc+" of live stream before loading audio fragment "+c.sn+" of level "+this.trackId),this.state= "WAITING_INIT_PTS"):(this.startFragRequested=!0,b.prototype.loadFragment.call(this,c,d,e)))},d.completeAudioSwitch=function(){var c=this.hls,d=this.trackId;this.media&&(this.log("Switching audio track : flushing all audio"),b.prototype.flushMainBuffer.call(this,0,Number.POSITIVE_INFINITY,"audio"));this.audioSwitch=!1;c.trigger(H.a.AUDIO_TRACK_SWITCHED,{id:d})},c}(Na),Qd=function(b){function c(c){var d;return(d=b.call(this,c,"[audio-track-controller]")||this).tracks=[],d.groupId=null,d.tracksInGroup= [],d.trackId=-1,d.trackName="",d.selectDefaultTrack=!0,d.registerListeners(),d}c.prototype=Object.create(b.prototype);c.prototype.constructor=c;da(c,b);var d,e=c.prototype;return e.registerListeners=function(){var b=this.hls;b.on(H.a.MANIFEST_LOADING,this.onManifestLoading,this);b.on(H.a.MANIFEST_PARSED,this.onManifestParsed,this);b.on(H.a.LEVEL_LOADING,this.onLevelLoading,this);b.on(H.a.LEVEL_SWITCHING,this.onLevelSwitching,this);b.on(H.a.AUDIO_TRACK_LOADED,this.onAudioTrackLoaded,this);b.on(H.a.ERROR, this.onError,this)},e.unregisterListeners=function(){var b=this.hls;b.off(H.a.MANIFEST_LOADING,this.onManifestLoading,this);b.off(H.a.MANIFEST_PARSED,this.onManifestParsed,this);b.off(H.a.LEVEL_LOADING,this.onLevelLoading,this);b.off(H.a.LEVEL_SWITCHING,this.onLevelSwitching,this);b.off(H.a.AUDIO_TRACK_LOADED,this.onAudioTrackLoaded,this);b.off(H.a.ERROR,this.onError,this)},e.destroy=function(){this.unregisterListeners();this.tracks.length=0;this.tracksInGroup.length=0;b.prototype.destroy.call(this)}, e.onManifestLoading=function(){this.tracks=[];this.groupId=null;this.tracksInGroup=[];this.trackId=-1;this.trackName="";this.selectDefaultTrack=!0},e.onManifestParsed=function(b,c){this.tracks=c.audioTracks||[]},e.onAudioTrackLoaded=function(b,c){var d=c.id,e=c.details,f=this.tracksInGroup[d];if(f){var g=f.details;f.details=c.details;this.log("audioTrack "+d+" loaded ["+e.startSN+"-"+e.endSN+"]");d===this.trackId&&(this.retryCount=0,this.playlistLoaded(d,c,g))}else this.warn("Invalid audio track id "+ d)},e.onLevelLoading=function(b,c){this.switchLevel(c.level)},e.onLevelSwitching=function(b,c){this.switchLevel(c.level)},e.switchLevel=function(b){b=this.hls.levels[b];if(null!=b&&b.audioGroupIds){var c=b.audioGroupIds[b.urlId];if(this.groupId!==c){this.groupId=c;b=this.tracks.filter(function(b){return!c||b.groupId===c});this.selectDefaultTrack&&!b.some(function(b){return b["default"]})&&(this.selectDefaultTrack=!1);this.tracksInGroup=b;var d={audioTracks:b};this.log("Updating audio tracks, "+b.length+ ' track(s) found in "'+c+'" group-id');this.hls.trigger(H.a.AUDIO_TRACKS_UPDATED,d);this.selectInitialTrack()}}},e.onError=function(c,d){b.prototype.onError.call(this,c,d);!d.fatal&&d.context&&d.context.type===Ua.AUDIO_TRACK&&d.context.id===this.trackId&&d.context.groupId===this.groupId&&this.retryLoadingOrFail(d)},e.setAudioTrack=function(b){var c=this.tracksInGroup;if(0>b||b>=c.length)this.warn("Invalid id passed to audio-track controller");else{this.clearTimer();var d=c[this.trackId];this.log("Now switching to audio-track index "+ b);var c=c[b],e=c.id,f=c.groupId,g=c.name,m=c.type,h=c.url;if(this.trackId=b,this.trackName=g,this.selectDefaultTrack=!1,this.hls.trigger(H.a.AUDIO_TRACK_SWITCHING,{id:e,groupId:void 0===f?"":f,name:g,type:m,url:h}),!c.details||c.details.live)b=this.switchParams(c.url,null==d?void 0:d.details),this.loadPlaylist(b)}},e.selectInitialTrack=function(){this.tracksInGroup;var b=this.findTrackId(this.trackName)||this.findTrackId();-1!==b?this.setAudioTrack(b):(this.warn("No track found for running audio group-ID: "+ this.groupId),this.hls.trigger(H.a.ERROR,{type:aa.b.MEDIA_ERROR,details:aa.a.AUDIO_TRACK_LOAD_ERROR,fatal:!0}))},e.findTrackId=function(b){for(var c=this.tracksInGroup,d=0;d=e[m].start&&g<=e[m].end){f=e[m];break}d=d.start+d.duration;f?f.end=d:(f={start:g,end:d},e.push(f))}},e.onMediaAttached=function(b,c){this.media=c.media;this.state="IDLE"},e.onMediaDetaching=function(){var b=this;this.media&&(this.fragmentTracker.removeAllFragments(),this.fragPrevious=null,this.currentTrackId=-1,this.levels.forEach(function(c){b.tracksBuffered[c.id]=[]}),this.media=null, this.mediaBuffer=null,this.state="STOPPED")},e.onError=function(b,c){var d,e=c.frag;e&&e.type===Za.SUBTITLE&&(null!==(d=this.fragCurrent)&&void 0!==d&&d.loader&&this.fragCurrent.loader.abort(),this.state="IDLE")},e.onSubtitleTracksUpdated=function(b,c){var d=this,e=c.subtitleTracks;this.tracksBuffered=[];this.levels=e.map(function(b){return new tc(b)});this.fragmentTracker.removeAllFragments();this.fragPrevious=null;this.levels.forEach(function(b){d.tracksBuffered[b.id]=[]});this.mediaBuffer=null}, e.onSubtitleTrackSwitch=function(b,c){if(this.currentTrackId=c.id,this.levels.length&&-1!==this.currentTrackId){var d=this.levels[this.currentTrackId];null!=d&&d.details?(this.mediaBuffer=this.mediaBufferTimeRanges,this.setInterval(500)):this.mediaBuffer=null}else this.clearInterval()},e.onSubtitleTrackLoaded=function(b,c){var d,e=c.id,f=c.details,g=this.currentTrackId,m=this.levels;if(m.length&&f){var h=m[g];if(!(e>=m.length||e!==g)&&h){if(this.mediaBuffer=this.mediaBufferTimeRanges,f.live||null!== (d=h.details)&&void 0!==d&&d.live){if(f.deltaUpdateFailed)return;this.alignPlaylists(f,h.details)}h.details=f;this.levelLastLoaded=e;this.setInterval(500)}}},e._handleFragmentLoadComplete=function(b){var c=b.frag;b=b.payload;var d=c.decryptdata,e=this.hls;if(!this.fragContextChanged(c)&&b&&0m)){var n,d=f[d].details,f=d.fragments,m=f.length,h=this.fragPrevious;cb||b>=e.length)||(this.clearTimer(),d=e[b],(this.log("Switching to subtitle track "+b),this.trackId=b,d)?(e=d.groupId,this.hls.trigger(H.a.SUBTITLE_TRACK_SWITCH,{id:d.id,groupId:void 0===e?"":e,name:d.name,type:d.type,url:d.url}), d=this.switchParams(d.url,null==c?void 0:c.details),this.loadPlaylist(d)):this.hls.trigger(H.a.SUBTITLE_TRACK_SWITCH,{id:b})):this.queuedDefaultTrack=b},f.onTextTracksChanged=function(){if(this.media&&this.hls.config.renderTextTracksNatively){for(var b=-1,c=xa(this.media.textTracks),d=0;de.config.appendErrorMaxRetry&&(V.b.error("[buffer-controller]: Failed "+e.config.appendErrorMaxRetry+" times to append segment in sourceBuffer"),c.fatal=!0));e.trigger(H.a.ERROR,c)}},h)},c.onBufferFlushing=function(b,c){var d=this,e=this.operationQueue, f=function(b){return{execute:d.removeExecutor.bind(d,b,c.startOffset,c.endOffset),onStart:function(){},onComplete:function(){d.hls.trigger(H.a.BUFFER_FLUSHED,{type:b})},onError:function(c){V.b.warn("[buffer-controller]: Failed to remove from "+b+" SourceBuffer",c)}}};c.type?e.append(f(c.type),c.type):(e.append(f("audio"),"audio"),e.append(f("video"),"video"))},c.onFragParsed=function(b,c){var d=this,e=c.frag,f=c.part,g=[],m=f?f.elementaryStreams:e.elementaryStreams;m[Ra.a.AUDIOVIDEO]?g.push("audiovideo"): (m[Ra.a.AUDIO]&&g.push("audio"),m[Ra.a.VIDEO]&&g.push("video"));0===g.length&&V.b.warn("Fragments must have at least one ElementaryStreamType set. type: "+e.type+" level: "+e.level+" sn: "+e.sn);this.blockBuffers(function(){var b=self.performance.now();e.stats.buffering.end=b;f&&(f.stats.buffering.end=b);d.hls.trigger(H.a.FRAG_BUFFERED,{frag:e,part:f,stats:f?f.stats:e.stats,id:e.type})},g)},c.onFragChanged=function(b,c){this.flushBackBuffer()},c.onBufferEos=function(b,c){var d=this;this.getSourceBufferTypes().reduce(function(b, e){var f=d.sourceBuffer[e];return c.type&&c.type!==e||f&&!f.ended&&(f.ended=!0,V.b.log("[buffer-controller]: "+e+" sourceBuffer now EOS")),b&&!(f&&!f.ended)},!0)&&this.blockBuffers(function(){var b=d.mediaSource;b&&"open"===b.readyState&&b.endOfStream()})},c.onLevelUpdated=function(b,c){var d=c.details;d.fragments.length&&(this.details=d,this.getSourceBufferTypes().length?this.blockBuffers(this.updateMediaElementDuration.bind(this)):this.updateMediaElementDuration())},c.flushBackBuffer=function(){var b= this.hls,c=this.details,d=this.media,e=this.sourceBuffer;if(d&&null!==c){var f=this.getSourceBufferTypes();if(f.length){var g=c.live&&null!==b.config.liveBackBufferLength?b.config.liveBackBufferLength:b.config.backBufferLength;if(Object(va.a)(g)&&!(0>g)){var m=c.levelTargetDuration,h=Math.floor(d.currentTime/m)*m-Math.max(g,m);f.forEach(function(d){var f=e[d];f&&(f=ub.getBuffered(f),0f.start(0)&&(b.trigger(H.a.BACK_BUFFER_REACHED,{bufferEnd:h}),c.live&&b.trigger(H.a.LIVE_BACK_BUFFER_REACHED, {bufferEnd:h}),b.trigger(H.a.BUFFER_FLUSHING,{startOffset:0,endOffset:h,type:d})))})}}}},c.updateMediaElementDuration=function(){if(this.details&&this.media&&this.mediaSource&&"open"===this.mediaSource.readyState){var b=this.details,c=this.hls,d=this.mediaSource,e=b.fragments[0].start+b.totalduration,f=this.media.duration,g=Object(va.a)(d.duration)?d.duration:0;b.live&&c.config.liveDurationInfinity?(V.b.log("[buffer-controller]: Media Source duration is set to Infinity"),d.duration=1/0,this.updateSeekableRange(b)): (e>g&&e>f||!Object(va.a)(f))&&(V.b.log("[buffer-controller]: Updating Media Source duration to "+e.toFixed(3)),d.duration=e)}},c.updateSeekableRange=function(b){var c=this.mediaSource,d=b.fragments;d.length&&b.live&&null!=c&&c.setLiveSeekableRange&&(d=Math.max(0,d[0].start),c.setLiveSeekableRange(d,Math.max(d,d+b.totalduration)))},c.checkPendingTracks=function(){var b=this.bufferCodecEventsExpected,c=this.operationQueue,d=this.pendingTracks,e=Object.keys(d).length;if(e&&!b||2===e){this.createSourceBuffers(d); this.pendingTracks={};b=Object.keys(this.sourceBuffer);if(0===b.length)return void this.hls.trigger(H.a.ERROR,{type:aa.b.MEDIA_ERROR,details:aa.a.BUFFER_INCOMPATIBLE_CODECS_ERROR,fatal:!0,reason:"could not create source buffer for media codec(s)"});b.forEach(function(b){c.executeNext(b)})}},c.createSourceBuffers=function(b){var c=this.sourceBuffer,d=this.mediaSource;if(!d)throw Error("createSourceBuffers called when mediaSource was null");var e=0,f;for(f in b)if(!c[f]){var g=b[f];if(!g)throw Error("source buffer exists for track "+ f+", however track does not");var m=g.levelCodec||g.codec,h=g.container+";codecs="+m;V.b.log("[buffer-controller]: creating sourceBuffer("+h+")");try{var n=c[f]=d.addSourceBuffer(h),v=f;this.addBufferListener(v,"updatestart",this._onSBUpdateStart);this.addBufferListener(v,"updateend",this._onSBUpdateEnd);this.addBufferListener(v,"error",this._onSBUpdateError);this.tracks[f]={buffer:n,codec:m,container:g.container,levelCodec:g.levelCodec,id:g.id};e++}catch(Ic){V.b.error("[buffer-controller]: error while trying to add sourceBuffer: "+ Ic.message),this.hls.trigger(H.a.ERROR,{type:aa.b.MEDIA_ERROR,details:aa.a.BUFFER_ADD_CODEC_ERROR,fatal:!1,error:Ic,mimeType:h})}}e&&this.hls.trigger(H.a.BUFFER_CREATED,{tracks:this.tracks})},c._onSBUpdateStart=function(b){this.operationQueue.current(b).onStart()},c._onSBUpdateEnd=function(b){var c=this.operationQueue;c.current(b).onComplete();c.shiftAndExecuteNext(b)},c._onSBUpdateError=function(b,c){V.b.error("[buffer-controller]: "+b+" SourceBuffer error",c);this.hls.trigger(H.a.ERROR,{type:aa.b.MEDIA_ERROR, details:aa.a.BUFFER_APPENDING_ERROR,fatal:!1});var d=this.operationQueue.current(b);d&&d.onError(c)},c.removeExecutor=function(b,c,d){var e=this.media,f=this.mediaSource,g=this.operationQueue,m=this.sourceBuffer[b];if(!e||!f||!m)return V.b.warn("[buffer-controller]: Attempting to remove from the "+b+" SourceBuffer, but it does not exist"),void g.shiftAndExecuteNext(b);e=Object(va.a)(e.duration)?e.duration:1/0;f=Object(va.a)(f.duration)?f.duration:1/0;c=Math.max(0,c);d=Math.min(d,e,f);d>c?(V.b.log("[buffer-controller]: Removing ["+ c+","+d+"] from the "+b+" SourceBuffer"),m.remove(c,d)):g.shiftAndExecuteNext(b)},c.appendExecutor=function(b,c){var d=this.operationQueue,e=this.sourceBuffer[c];if(!e)return V.b.warn("[buffer-controller]: Attempting to append to the "+c+" SourceBuffer, but it does not exist"),void d.shiftAndExecuteNext(c);e.ended=!1;e.appendBuffer(b)},c.blockBuffers=function(b,c){var d=this;if(void 0===c&&(c=this.getSourceBufferTypes()),!c.length)return V.b.log("[buffer-controller]: Blocking operation requested, but no SourceBuffers exist"), void Promise.resolve(b);var e=this.operationQueue,f=c.map(function(b){return e.appendBlocker(b)});Promise.all(f).then(function(){b();c.forEach(function(b){var c=d.sourceBuffer[b];c&&c.updating||e.shiftAndExecuteNext(b)})})},c.getSourceBufferTypes=function(){return Object.keys(this.sourceBuffer)},c.addBufferListener=function(b,c,d){var e=this.sourceBuffer[b];e&&(d=d.bind(this,b),this.listeners[b].push({event:c,listener:d}),e.addEventListener(c,d))},c.removeBufferListeners=function(b){var c=this.sourceBuffer[b]; c&&this.listeners[b].forEach(function(b){c.removeEventListener(b.event,b.listener)})},b}(),fd={42:225,92:233,94:237,95:243,96:250,123:231,124:247,125:209,126:241,127:9608,128:174,129:176,130:189,131:191,132:8482,133:162,134:163,135:9834,136:224,137:32,138:232,139:226,140:234,141:238,142:244,143:251,144:193,145:201,146:211,147:218,148:220,149:252,150:8216,151:161,152:42,153:8217,154:9473,155:169,156:8480,157:8226,158:8220,159:8221,160:192,161:194,162:199,163:200,164:202,165:203,166:235,167:206,168:207, 169:239,170:212,171:217,172:249,173:219,174:171,175:187,176:195,177:227,178:205,179:204,180:236,181:210,182:242,183:213,184:245,185:123,186:125,187:92,188:94,189:95,190:124,191:8764,192:196,193:228,194:214,195:246,196:223,197:165,198:164,199:9475,200:197,201:229,202:216,203:248,204:9487,205:9491,206:9495,207:9499},Tc=function(b){var c=b;return fd.hasOwnProperty(b)&&(c=fd[b]),String.fromCharCode(c)},Sd={17:1,18:3,21:5,22:7,23:9,16:11,19:12,20:14},Bd={17:2,18:4,21:6,22:8,23:10,19:13,20:15},Cd={25:1, 26:3,29:5,30:7,31:9,24:11,27:12,28:14},gd={25:2,26:4,29:6,30:8,31:10,27:13,28:15},db="white green blue cyan red yellow magenta black transparent".split(" ");!function(b){b[b.ERROR=0]="ERROR";b[b.TEXT=1]="TEXT";b[b.WARNING=2]="WARNING";b[b.INFO=2]="INFO";b[b.DEBUG=3]="DEBUG";b[b.DATA=3]="DATA"}(fb||(fb={}));var Vb=function(){function b(){this.time=null;this.verboseLevel=fb.ERROR}return b.prototype.log=function(b,c){this.verboseLevel>=b&&V.b.log(this.time+" ["+b+"] "+c)},b}(),sc=function(b){for(var c= [],d=0;dc;c++)this.chars.push(new Td);this.logger=b;this.pos=0;this.currPenState=new Dd}var c=b.prototype;return c.equals=function(b){for(var c=!0,d=0;100> d;d++)if(!this.chars[d].equals(b.chars[d])){c=!1;break}return c},c.copy=function(b){for(var c=0;100>c;c++)this.chars[c].copy(b.chars[c])},c.isEmpty=function(){for(var b=!0,c=0;100>c;c++)if(!this.chars[c].isEmpty()){b=!1;break}return b},c.setCursor=function(b){this.pos!==b&&(this.pos=b);0>this.pos?(this.logger.log(fb.DEBUG,"Negative cursor position "+this.pos),this.pos=0):100b;b++)this.chars[b].reset()}, c.clear=function(){this.clearFromPos(0);this.pos=0;this.currPenState.reset()},c.clearToEndOfRow=function(){this.clearFromPos(this.pos)},c.getTextString=function(){for(var b=[],c=!0,d=0;100>d;d++){var e=this.chars[d].uchar;" "!==e&&(c=!1);b.push(e)}return c?"":b.join("")},c.setPenStyles=function(b){this.currPenState.setStyles(b);this.chars[this.pos].setPenState(this.currPenState)},b}(),Uc=function(){function b(b){this.logger=this.lastOutputScreen=this.nrRollUpRows=this.currRow=this.rows=void 0;this.rows= [];for(var c=0;15>c;c++)this.rows.push(new Ud(b));this.logger=b;this.currRow=14;this.lastOutputScreen=this.nrRollUpRows=null;this.reset()}var c=b.prototype;return c.reset=function(){for(var b=0;15>b;b++)this.rows[b].clear();this.currRow=14},c.equals=function(b){for(var c=!0,d=0;15>d;d++)if(!this.rows[d].equals(b.rows[d])){c=!1;break}return c},c.copy=function(b){for(var c=0;15>c;c++)this.rows[c].copy(b.rows[c])},c.isEmpty=function(){for(var b=!0,c=0;15>c;c++)if(!this.rows[c].isEmpty()){b=!1;break}return b}, c.backSpace=function(){this.rows[this.currRow].backSpace()},c.clearToEndOfRow=function(){this.rows[this.currRow].clearToEndOfRow()},c.insertChar=function(b){this.rows[this.currRow].insertChar(b)},c.setPen=function(b){this.rows[this.currRow].setPenStyles(b)},c.moveCursor=function(b){this.rows[this.currRow].moveCursor(b)},c.setCursor=function(b){this.logger.log(fb.INFO,"setCursor: "+b);this.rows[this.currRow].setCursor(b)},c.setPAC=function(b){this.logger.log(fb.INFO,"pacData = "+JSON.stringify(b)); var c=b.row-1;if(this.nrRollUpRows&&cd;d++)this.rows[d].clear();var d=this.currRow+1-this.nrRollUpRows,e=this.lastOutputScreen;if(e){var f=e.rows[d].cueStartTime,g=this.logger.time;if(f&&null!==g&&ff;f++){var g=this.rows[f].getTextString();g&&(e=f+1,b?c.push("Row "+e+": '"+g+"'"):c.push(g.trim()))}return 0 ("+sc([e,f])+")"),(d=this.parseCmd(e,f))||(d=this.parseMidrow(e,f)),d||(d=this.parsePAC(e,f)),d||(d=this.parseBackgroundAttributes(e,f)),!d&&(g=this.parseChars(e,f))){var h=this.currentChannel;h&&0=c||(23===b||31===b)&&33<=c&&35>=c))return!1;if(d.a===b&&d.b===c)return d.a=null,d.b=null,this.logger.log(fb.DEBUG,"Repeated command ("+sc([b,c])+") is dropped"),!0;var e=20===b||21===b||23===b?1:2,f=this.channels[e];20===b||21===b||28===b||29===b?32===c?f.ccRCL():33===c?f.ccBS():34===c?f.ccAOF():35===c?f.ccAON():36===c?f.ccDER():37=== c?f.ccRU(2):38===c?f.ccRU(3):39===c?f.ccRU(4):40===c?f.ccFON():41===c?f.ccRDC():42===c?f.ccTR():43===c?f.ccRTD():44===c?f.ccEDM():45===c?f.ccCR():46===c?f.ccENM():47===c&&f.ccEOC():f.ccTO(c-32);d.a=b;d.b=c;return this.currentChannel=e,!0},c.parseMidrow=function(b,c){var d;if((17===b||25===b)&&32<=c&&47>=c){if((d=17===b?1:2)!==this.currentChannel)return this.logger.log(fb.ERROR,"Mismatch channel in midrow parsing"),!1;d=this.channels[d];return!!d&&(d.ccMIDROW(c),this.logger.log(fb.DEBUG,"MIDROW ("+ sc([b,c])+")"),!0)}return!1},c.parsePAC=function(b,c){var d,e=this.cmdHistory;if(!((17<=b&&23>=b||25<=b&&31>=b)&&64<=c&&127>=c||(16===b||24===b)&&64<=c&&95>=c))return!1;if(e.a===b&&e.b===c)return e.a=null,e.b=null,!0;var f=23>=b?1:2;d=64<=c&&95>=c?1===f?Sd[b]:Cd[b]:1===f?Bd[b]:gd[b];var g=this.channels[f],m;if(m=!!g)g.setPAC(this.interpretPAC(d,c)),e.a=b,e.b=c,m=(this.currentChannel=f,!0);return m},c.interpretPAC=function(b,c){var d,e={color:null,italics:!1,indent:null,underline:!1,row:b};return d= 95=d?e.color="white green blue cyan red yellow magenta white".split(" ")[Math.floor(d/2)]:15>=d?(e.italics=!0,e.color="white"):e.indent=4*Math.floor((d-16)/2),e},c.parseChars=function(b,c){var d,e,f=null,g=null;(25<=b?(d=2,g=b-8):(d=1,g=b),17<=g&&19>=g)?(e=17===g?c+80:18===g?c+112:c+144,this.logger.log(fb.INFO,"Special char '"+Tc(e)+"' in channel "+d),f=[e]):32<=b&&127>=b&&(f=0===c?[b]:[b,c]);f&&(d=sc(f),this.logger.log(fb.DEBUG,"Char codes = "+d.join(",")),d= this.cmdHistory,d.a=b,d.b=c);return f},c.parseBackgroundAttributes=function(b,c){var d;if(!((16===b||24===b)&&32<=c&&47>=c||(23===b||31===b)&&45<=c&&47>=c))return!1;var e={};16===b||24===b?(d=Math.floor((c-32)/2),e.background=db[d],1==c%2&&(e.background+="_semi")):45===c?e.background="transparent":(e.foreground="black",47===c&&(e.underline=!0));this.channels[23>=b?1:2].setBkgData(e);d=this.cmdHistory;d.a=b;d.b=c;return!0},c.reset=function(){for(var b=0;bb)&&(this.startTime=b);this.endTime=c;this.screen=d;this.timelineController.createCaptionsTrack(this.trackName)},c.reset=function(){this.cueRanges=[]},b}(),kc=function(){function b(b,c){if("string"!=typeof c||!Array.isArray(b))return!1;var d=c.toLowerCase();return!!~b.indexOf(d)&&d}function c(b){for(var c=arguments.length,d=Array(1b||100b||100=d)return this.set(b,d),!0}return!1},b}(),ad=new kc(0, 0,""),Lc="middle"===ad.align?"middle":"center",Id=function(){function b(){this.state="INITIAL";this.buffer="";this.decoder=new Vd;this.regionList=[];this.cue=null;this.onflush=this.onparsingerror=this.oncue=void 0}var c=b.prototype;return c.parse=function(b){function c(){for(var b=d.buffer,c=0,b=b.replace(//gi,"\n");c>>0).toString()},Bc=/^(\d{2,}):(\d{2}):(\d{2}):(\d{2})\.?(\d+)?$/,Oc=/^(\d*(?:\.\d*)?)(h|m|s|ms|f|t)$/,Md={left:"start",center:"center",right:"end",start:"start",end:"end"},id=function(){function c(b){if(this.hls=void 0,this.media=null,this.config=void 0,this.enabled=!0,this.Cues=void 0,this.textTracks=[],this.tracks=[],this.initPTS=[],this.timescale=[],this.unparsedVttFrags=[],this.captionsTracks={},this.nonNativeCaptionsTracks={},this.cea608Parser1= void 0,this.cea608Parser2=void 0,this.lastSn=-1,this.prevCC=-1,this.vttCCs={ccOffset:0,presentationOffset:0,0:{start:0,prevCC:-1,"new":!1}},this.captionsProperties=void 0,this.hls=b,this.config=b.config,this.Cues=b.config.cueHandler,this.captionsProperties={textTrack1:{label:this.config.captionsTextTrack1Label,languageCode:this.config.captionsTextTrack1LanguageCode},textTrack2:{label:this.config.captionsTextTrack2Label,languageCode:this.config.captionsTextTrack2LanguageCode},textTrack3:{label:this.config.captionsTextTrack3Label, languageCode:this.config.captionsTextTrack3LanguageCode},textTrack4:{label:this.config.captionsTextTrack4Label,languageCode:this.config.captionsTextTrack4LanguageCode}},this.config.enableCEA708Captions){var c=new Vc(this,"textTrack1"),d=new Vc(this,"textTrack2"),e=new Vc(this,"textTrack3"),f=new Vc(this,"textTrack4");this.cea608Parser1=new hd(1,c,d);this.cea608Parser2=new hd(3,e,f)}b.on(H.a.MEDIA_ATTACHING,this.onMediaAttaching,this);b.on(H.a.MEDIA_DETACHING,this.onMediaDetaching,this);b.on(H.a.MANIFEST_LOADING, this.onManifestLoading,this);b.on(H.a.MANIFEST_LOADED,this.onManifestLoaded,this);b.on(H.a.SUBTITLE_TRACKS_UPDATED,this.onSubtitleTracksUpdated,this);b.on(H.a.FRAG_LOADING,this.onFragLoading,this);b.on(H.a.FRAG_LOADED,this.onFragLoaded,this);b.on(H.a.FRAG_PARSING_USERDATA,this.onFragParsingUserdata,this);b.on(H.a.FRAG_DECRYPTED,this.onFragDecrypted,this);b.on(H.a.INIT_PTS_FOUND,this.onInitPtsFound,this);b.on(H.a.SUBTITLE_TRACKS_CLEARED,this.onSubtitleTracksCleared,this);b.on(H.a.BUFFER_FLUSHING,this.onBufferFlushing, this)}var g=c.prototype;return g.destroy=function(){var b=this.hls;b.off(H.a.MEDIA_ATTACHING,this.onMediaAttaching,this);b.off(H.a.MEDIA_DETACHING,this.onMediaDetaching,this);b.off(H.a.MANIFEST_LOADING,this.onManifestLoading,this);b.off(H.a.MANIFEST_LOADED,this.onManifestLoaded,this);b.off(H.a.SUBTITLE_TRACKS_UPDATED,this.onSubtitleTracksUpdated,this);b.off(H.a.FRAG_LOADING,this.onFragLoading,this);b.off(H.a.FRAG_LOADED,this.onFragLoaded,this);b.off(H.a.FRAG_PARSING_USERDATA,this.onFragParsingUserdata, this);b.off(H.a.FRAG_DECRYPTED,this.onFragDecrypted,this);b.off(H.a.INIT_PTS_FOUND,this.onInitPtsFound,this);b.off(H.a.SUBTITLE_TRACKS_CLEARED,this.onSubtitleTracksCleared,this);b.off(H.a.BUFFER_FLUSHING,this.onBufferFlushing,this);this.hls=this.config=this.cea608Parser1=this.cea608Parser2=null},g.addCues=function(b,c,d,e,f){for(var g,m,h,n,v=!1,r=f.length;r--;){var q=f[r],w=(g=q[0],m=q[1],h=c,n=d,Math.min(m,n)-Math.max(g,h));if(0<=w&&(q[0]=Math.min(q[0],c),q[1]=Math.max(q[1],d),v=!0,.5this.autoLevelCapping&&this.streamController&&this.streamController.nextLevelSwitch();this.autoLevelCapping=c.autoLevelCapping}}},e.getMaxLevel=function(c){var d=this,e=this.hls.levels;if(!e.length)return-1;e=e.filter(function(e,f){return b.isLevelAllowed(f,d.restrictedLevels)&&f<=c});return this.clientRect=null,b.getMaxLevelByMediaSize(e,this.mediaWidth, this.mediaHeight)},e.startCapping=function(){this.timer||(this.autoLevelCapping=Number.POSITIVE_INFINITY,this.hls.firstLevel=this.getMaxLevel(this.firstLevel),self.clearInterval(this.timer),this.timer=self.setInterval(this.detectPlayerSize.bind(this),1E3),this.detectPlayerSize())},e.stopCapping=function(){this.restrictedLevels=[];this.firstLevel=-1;this.autoLevelCapping=Number.POSITIVE_INFINITY;this.timer&&(self.clearInterval(this.timer),this.timer=void 0)},e.getDimensions=function(){if(this.clientRect)return this.clientRect; var b=this.media,c={width:0,height:0};if(b){var d=b.getBoundingClientRect();c.width=d.width;c.height=d.height;c.width||c.height||(c.width=d.right-d.left||b.width||0,c.height=d.bottom-d.top||b.height||0)}return this.clientRect=c,c},b.isLevelAllowed=function(b,c){return void 0===c&&(c=[]),-1===c.indexOf(b)},b.getMaxLevelByMediaSize=function(b,c,d){if(!b||!b.length)return-1;for(var e,f,g=b.length-1,m=0;m=c||h.height>=d)&&(e=h,!(f=b[m+1])||e.width!==f.width||e.height!== f.height)){g=m;break}}return g},d=[{key:"contentScaleFactor",get:function(){var b=1;try{b=self.devicePixelRatio}catch(Ma){}return b}}],c=[{key:"mediaWidth",get:function(){return this.getDimensions().width*b.contentScaleFactor}},{key:"mediaHeight",get:function(){return this.getDimensions().height*b.contentScaleFactor}}],Ca(b.prototype,c),d&&Ca(b,d),b}(),Fd=function(){function b(b){this.hls=void 0;this.isVideoPlaybackQualityAvailable=!1;this.timer=void 0;this.media=null;this.lastTime=void 0;this.lastDecodedFrames= this.lastDroppedFrames=0;this.streamController=void 0;this.hls=b;this.registerListeners()}var c=b.prototype;return c.setStreamController=function(b){this.streamController=b},c.registerListeners=function(){this.hls.on(H.a.MEDIA_ATTACHING,this.onMediaAttaching,this)},c.unregisterListeners=function(){this.hls.off(H.a.MEDIA_ATTACHING,this.onMediaAttaching)},c.destroy=function(){this.timer&&clearInterval(this.timer);this.unregisterListeners();this.isVideoPlaybackQualityAvailable=!1;this.media=null},c.onMediaAttaching= function(b,c){var d=this.hls.config;if(d.capLevelOnFPSDrop){var e=c.media instanceof self.HTMLVideoElement?c.media:null;(this.media=e)&&"function"==typeof e.getVideoPlaybackQuality&&(this.isVideoPlaybackQualityAvailable=!0);self.clearInterval(this.timer);this.timer=self.setTimeout(this.checkFPSInterval.bind(this),d.fpsDroppedMonitoringPeriod)}},c.checkFPS=function(b,c,d){b=performance.now();if(c){if(this.lastTime){var e=d-this.lastDroppedFrames,f=c-this.lastDecodedFrames,g=1E3*e/(b-this.lastTime), m=this.hls;if(m.trigger(H.a.FPS_DROP,{currentDropped:e,currentDecoded:f,totalDroppedFrames:d}),0m.config.fpsDroppedMonitoringThreshold*f)e=m.currentLevel,V.b.warn("drop FPS ratio greater than max allowed value for currentLevel: "+e),0=e)&&(--e,m.trigger(H.a.FPS_DROP_LEVEL_CAPPING,{level:e,droppedLevel:m.currentLevel}),m.autoLevelCapping=e,this.streamController.nextLevelSwitch())}this.lastTime=b;this.lastDroppedFrames=d;this.lastDecodedFrames= c}},c.checkFPSInterval=function(){var b=this.media;if(b)if(this.isVideoPlaybackQualityAvailable){var c=b.getVideoPlaybackQuality();this.checkFPS(b,c.totalVideoFrames,c.droppedVideoFrames)}else this.checkFPS(b,b.webkitDecodedFrameCount,b.webkitDroppedFrameCount)},b}();!function(b){b.WIDEVINE="com.widevine.alpha";b.PLAYREADY="com.microsoft.playready"}(fc||(fc={}));var Wc="undefined"!=typeof self&&self.navigator&&self.navigator.requestMediaKeySystemAccess?self.navigator.requestMediaKeySystemAccess.bind(self.navigator): null,R=function(){function b(b){this._config=this._drmSystemOptions=this._requestMediaKeySystemAccess=this._emeEnabled=this._licenseResponseCallback=this._licenseXhrSetup=this._widevineLicenseUrl=this.hls=void 0;this._mediaKeysList=[];this._media=null;this._hasSetMediaKeys=!1;this._requestLicenseFailureCount=0;this.mediaKeysPromise=null;this._onMediaEncrypted=this.onMediaEncrypted.bind(this);this.hls=b;this._config=b.config;this._widevineLicenseUrl=this._config.widevineLicenseUrl;this._licenseXhrSetup= this._config.licenseXhrSetup;this._licenseResponseCallback=this._config.licenseResponseCallback;this._emeEnabled=this._config.emeEnabled;this._requestMediaKeySystemAccess=this._config.requestMediaKeySystemAccessFunc;this._drmSystemOptions=this._config.drmSystemOptions;this._registerListeners()}var c,d=b.prototype;return d.destroy=function(){this._unregisterListeners();this._requestMediaKeySystemAccess=this.hls=this._onMediaEncrypted=null},d._registerListeners=function(){this.hls.on(H.a.MEDIA_ATTACHED, this.onMediaAttached,this);this.hls.on(H.a.MEDIA_DETACHED,this.onMediaDetached,this);this.hls.on(H.a.MANIFEST_PARSED,this.onManifestParsed,this)},d._unregisterListeners=function(){this.hls.off(H.a.MEDIA_ATTACHED,this.onMediaAttached,this);this.hls.off(H.a.MEDIA_DETACHED,this.onMediaDetached,this);this.hls.off(H.a.MANIFEST_PARSED,this.onManifestParsed,this)},d.getLicenseServerUrl=function(b){switch(b){case fc.WIDEVINE:if(this._widevineLicenseUrl)return this._widevineLicenseUrl}throw Error('no license server URL configured for key-system "'+ b+'"');},d._attemptKeySystemAccess=function(b,c,d){var e=this;c=function(b,c,d,e){switch(b){case fc.WIDEVINE:return function(b,c,d){var e={audioCapabilities:[],videoCapabilities:[]};return b.forEach(function(b){e.audioCapabilities.push({contentType:'audio/mp4; codecs="'+b+'"',robustness:d.audioRobustness||""})}),c.forEach(function(b){e.videoCapabilities.push({contentType:'video/mp4; codecs="'+b+'"',robustness:d.videoRobustness||""})}),[e]}(c,d,e);default:throw Error("Unknown key-system: "+b);}}(b, c,d,this._drmSystemOptions);V.b.log("Requesting encrypted media key-system access");c=this.requestMediaKeySystemAccess(b,c);this.mediaKeysPromise=c.then(function(c){return e._onMediaKeySystemAccessObtained(b,c)});c["catch"](function(c){V.b.error('Failed to obtain key-system "'+b+'" access:',c)})},d._onMediaKeySystemAccessObtained=function(b,c){var d=this;V.b.log('Access for key-system "'+b+'" obtained');var e={mediaKeysSessionInitialized:!1,mediaKeySystemAccess:c,mediaKeySystemDomain:b};this._mediaKeysList.push(e); var f=Promise.resolve().then(function(){return c.createMediaKeys()}).then(function(c){return e.mediaKeys=c,V.b.log('Media-keys created for key-system "'+b+'"'),d._onMediaKeysCreated(),c});return f["catch"](function(b){V.b.error("Failed to create media-keys:",b)}),f},d._onMediaKeysCreated=function(){var b=this;this._mediaKeysList.forEach(function(c){c.mediaKeysSession||(c.mediaKeysSession=c.mediaKeys.createSession(),b._onNewMediaKeySession(c.mediaKeysSession))})},d._onNewMediaKeySession=function(b){var c= this;V.b.log("New key-system session "+b.sessionId);b.addEventListener("message",function(d){c._onKeySessionMessage(b,d.message)},!1)},d._onKeySessionMessage=function(b,c){V.b.log("Got EME message event, creating license request");this._requestLicense(c,function(c){V.b.log("Received license data (length: "+(c?c.byteLength:c)+"), updating key-session");b.update(c)})},d.onMediaEncrypted=function(b){var c=this;if(V.b.log('Media is encrypted using "'+b.initDataType+'" init data type'),!this.mediaKeysPromise)return V.b.error("Fatal: Media is encrypted but no CDM access or no keys have been requested"), void this.hls.trigger(H.a.ERROR,{type:aa.b.KEY_SYSTEM_ERROR,details:aa.a.KEY_SYSTEM_NO_KEYS,fatal:!0});var d=function(d){c._media&&(c._attemptSetMediaKeys(d),c._generateRequestWithPreferredKeySession(b.initDataType,b.initData))};this.mediaKeysPromise.then(d)["catch"](d)},d._attemptSetMediaKeys=function(b){if(!this._media)throw Error("Attempted to set mediaKeys without first attaching a media element");if(!this._hasSetMediaKeys){b=this._mediaKeysList[0];if(!b||!b.mediaKeys)return V.b.error("Fatal: Media is encrypted but no CDM access or no keys have been obtained yet"), void this.hls.trigger(H.a.ERROR,{type:aa.b.KEY_SYSTEM_ERROR,details:aa.a.KEY_SYSTEM_NO_KEYS,fatal:!0});V.b.log("Setting keys for encrypted media");this._media.setMediaKeys(b.mediaKeys);this._hasSetMediaKeys=!0}},d._generateRequestWithPreferredKeySession=function(b,c){var d=this,e=this._mediaKeysList[0];if(!e)return V.b.error("Fatal: Media is encrypted but not any key-system access has been obtained yet"),void this.hls.trigger(H.a.ERROR,{type:aa.b.KEY_SYSTEM_ERROR,details:aa.a.KEY_SYSTEM_NO_ACCESS, fatal:!0});if(e.mediaKeysSessionInitialized)V.b.warn("Key-Session already initialized but requested again");else{var f=e.mediaKeysSession;if(!f)return V.b.error("Fatal: Media is encrypted but no key-session existing"),void this.hls.trigger(H.a.ERROR,{type:aa.b.KEY_SYSTEM_ERROR,details:aa.a.KEY_SYSTEM_NO_SESSION,fatal:!0});if(!c)return V.b.warn("Fatal: initData required for generating a key session is null"),void this.hls.trigger(H.a.ERROR,{type:aa.b.KEY_SYSTEM_ERROR,details:aa.a.KEY_SYSTEM_NO_INIT_DATA, fatal:!0});V.b.log('Generating key-session request for "'+b+'" init data type');e.mediaKeysSessionInitialized=!0;f.generateRequest(b,c).then(function(){V.b.debug("Key-session generation succeeded")})["catch"](function(b){V.b.error("Error generating key-session request:",b);d.hls.trigger(H.a.ERROR,{type:aa.b.KEY_SYSTEM_ERROR,details:aa.a.KEY_SYSTEM_NO_SESSION,fatal:!1})})}},d._createLicenseXhr=function(b,c,d){var e=new XMLHttpRequest;e.responseType="arraybuffer";e.onreadystatechange=this._onLicenseRequestReadyStageChange.bind(this, e,b,c,d);if(c=this._licenseXhrSetup)try{c.call(this.hls,e,b),c=void 0}catch(Wb){V.b.error(Wb)}try{e.readyState||e.open("POST",b,!0),c&&c.call(this.hls,e,b)}catch(Wb){throw Error("issue setting up KeySystem license XHR "+Wb);}return e},d._onLicenseRequestReadyStageChange=function(b,c,d,e){switch(b.readyState){case 4:if(200===b.status){this._requestLicenseFailureCount=0;V.b.log("License request succeeded");d=b.response;var f=this._licenseResponseCallback;if(f)try{d=f.call(this.hls,b,c)}catch(jc){V.b.error(jc)}e(d)}else{if(V.b.error("License Request XHR failed ("+ c+"). Status: "+b.status+" ("+b.statusText+")"),this._requestLicenseFailureCount++,3e){var g, m;if(d.loading.end=Math.max(self.performance.now(),d.loading.first),m="arraybuffer"===b.responseType?(g=c.response).byteLength:(g=c.responseText).length,d.loaded=d.total=m,this.callbacks)if(f=this.callbacks.onProgress,f&&f(d,b,g,c),this.callbacks)this.callbacks.onSuccess({url:c.responseURL,data:g},d,b,c)}else d.retry>=f.maxRetry||400<=e&&499>e?(V.b.error(e+" while loading "+b.url),this.callbacks.onError({code:e,text:c.statusText},b,c)):(V.b.warn(e+" while loading "+b.url+", retrying in "+this.retryDelay+ "..."),this.abortInternal(),this.loader=null,self.clearTimeout(this.retryTimeout),this.retryTimeout=self.setTimeout(this.loadInternal.bind(this),this.retryDelay),this.retryDelay=Math.min(2*this.retryDelay,f.maxRetryDelay),d.retry++);else self.clearTimeout(this.requestTimeout),this.requestTimeout=self.setTimeout(this.loadtimeout.bind(this),f.timeout)}},c.loadtimeout=function(){V.b.warn("timeout while loading "+this.context.url);var b=this.callbacks;b&&(this.abortInternal(),b.onTimeout(this.stats,this.context, this.loader))},c.loadprogress=function(b){var c=this.stats;c.loaded=b.loaded;b.lengthComputable&&(c.total=b.total)},c.getCacheAge=function(){var b=null;this.loader&&Wd.test(this.loader.getAllResponseHeaders())&&(b=(b=this.loader.getResponseHeader("age"))?parseFloat(b):null);return b},b}(),mb=function(){function b(b){this.context=this.controller=this.response=this.request=this.requestTimeout=this.fetchSetup=void 0;this.callbacks=this.config=null;this.stats=void 0;this.loader=null;this.fetchSetup=b.fetchSetup|| ka;this.controller=new self.AbortController;this.stats=new ab.a}var c=b.prototype;return c.destroy=function(){this.loader=this.callbacks=null;this.abortInternal()},c.abortInternal=function(){this.stats.aborted=!0;this.controller.abort()},c.abort=function(){var b;this.abortInternal();null!==(b=this.callbacks)&&void 0!==b&&b.onAbort&&this.callbacks.onAbort(this.stats,this.context,this.response)},c.load=function(b,c,d){var e=this,f=this.stats;if(f.loading.start)throw Error("Loader can only be used once."); f.loading.start=self.performance.now();var g=function(b,c){var d={method:"GET",mode:"cors",credentials:"same-origin",signal:c};b.rangeEnd&&(d.headers=new self.Headers({Range:"bytes="+b.rangeStart+"-"+String(b.rangeEnd-1)}));return d}(b,this.controller.signal),m=d.onProgress,h="arraybuffer"===b.responseType,n=h?"byteLength":"length";this.context=b;this.config=c;this.callbacks=d;this.request=this.fetchSetup(b,g);self.clearTimeout(this.requestTimeout);this.requestTimeout=self.setTimeout(function(){e.abortInternal(); d.onTimeout(f,b,e.response)},c.timeout);self.fetch(this.request).then(function(d){if(e.response=e.loader=d,!d.ok)throw new kd(d.statusText||"fetch, bad network response",d.status,d);return f.loading.first=Math.max(self.performance.now(),f.loading.start),f.total=parseInt(d.headers.get("Content-Length")||"0"),m&&Object(va.a)(c.highWaterMark)?e.loadProgressively(d,f,b,c.highWaterMark,m):h?d.arrayBuffer():d.text()}).then(function(g){var h=e.response;self.clearTimeout(e.requestTimeout);f.loading.end=Math.max(self.performance.now(), f.loading.first);f.loaded=f.total=g[n];var v={url:h.url,data:g};m&&!Object(va.a)(c.highWaterMark)&&m(f,b,g,h);d.onSuccess(v,f,b,h)})["catch"](function(c){if(self.clearTimeout(e.requestTimeout),!f.aborted)d.onError({code:c.code||0,text:c.message},b,c.details)})},c.getCacheAge=function(){var b=null;this.response&&(b=(b=this.response.headers.get("age"))?parseFloat(b):null);return b},c.loadProgressively=function(b,c,d,e,f){void 0===e&&(e=0);var g=new yd.a,m=b.body.getReader();return function Yb(){return m.read().then(function(m){if(m.done)return g.dataLength&& f(c,d,g.flush(),b),Promise.resolve(new ArrayBuffer(0));m=m.value;var h=m.length;return c.loaded+=h,h=e&&f(c,d,g.flush(),b)):f(c,d,m,b),Yb()})["catch"](function(){return Promise.reject()})}()},b}(),kd=function(b){function c(c,d,e){var f;return(f=b.call(this,c)||this).code=void 0,f.details=void 0,f.code=d,f.details=e,f}return c.prototype=Object.create(b.prototype),c.prototype.constructor=c,wa(c,b),c}(fa(Error)),Gd=/\s/,nc=U(U({autoStartLoad:!0,startPosition:-1, defaultAudioCodec:void 0,debug:!1,capLevelOnFPSDrop:!1,capLevelToPlayerSize:!1,initialLiveManifestSize:1,maxBufferLength:30,backBufferLength:1/0,maxBufferSize:6E7,maxBufferHole:.1,highBufferWatchdogPeriod:2,nudgeOffset:.1,nudgeMaxRetry:3,maxFragLookUpTolerance:.25,liveSyncDurationCount:3,liveMaxLatencyDurationCount:1/0,liveSyncDuration:void 0,liveMaxLatencyDuration:void 0,maxLiveSyncPlaybackRate:1,liveDurationInfinity:!1,liveBackBufferLength:null,maxMaxBufferLength:600,enableWorker:!0,enableSoftwareAES:!0, manifestLoadingTimeOut:1E4,manifestLoadingMaxRetry:1,manifestLoadingRetryDelay:1E3,manifestLoadingMaxRetryTimeout:64E3,startLevel:void 0,levelLoadingTimeOut:1E4,levelLoadingMaxRetry:4,levelLoadingRetryDelay:1E3,levelLoadingMaxRetryTimeout:64E3,fragLoadingTimeOut:2E4,fragLoadingMaxRetry:6,fragLoadingRetryDelay:1E3,fragLoadingMaxRetryTimeout:64E3,startFragPrefetch:!1,fpsDroppedMonitoringPeriod:5E3,fpsDroppedMonitoringThreshold:.2,appendErrorMaxRetry:3,loader:jd,fLoader:void 0,pLoader:void 0,xhrSetup:void 0, licenseXhrSetup:void 0,licenseResponseCallback:void 0,abrController:xd,bufferController:sb,capLevelController:Ed,fpsController:Fd,stretchShortVideoTrack:!1,maxAudioFramesDrift:1,forceKeyFrameOnDiscontinuity:!0,abrEwmaFastLive:3,abrEwmaSlowLive:9,abrEwmaFastVoD:3,abrEwmaSlowVoD:9,abrEwmaDefaultEstimate:5E5,abrBandWidthFactor:.95,abrBandWidthUpFactor:.7,abrMaxWithRealBitrate:!1,maxStarvationDelay:4,maxLoadingDelay:4,minAutoBitrate:0,emeEnabled:!1,widevineLicenseUrl:void 0,drmSystemOptions:{},requestMediaKeySystemAccessFunc:Wc, testBandwidth:!0,progressive:!1,lowLatencyMode:!0},{cueHandler:{newCue:function(b,c,d,e){for(var g,m,h,n,v,q=[],r=self.VTTCue||self.TextTrackCue,w=0;w/gi,"\n");h=ya(c,d,g);b&&b.cues&&b.cues.getCueById(h)||((m=new r(c,d,g)).id=h,m.line=w+1,m.align="left",m.position=10+ Math.min(80,10*Math.floor(8*n/32)),q.push(m))}return b&&q.length&&(q.sort(function(b,c){return"auto"===b.line||"auto"===c.line?0:8 c)return e;return 0}},{key:"maxAutoLevel",get:function(){var b=this.levels,c=this.autoLevelCapping;return-1===c&&b&&b.length?b.length-1:c}},{key:"nextAutoLevel",get:function(){return Math.min(Math.max(this.abrController.nextAutoLevel,this.minAutoLevel),this.maxAutoLevel)},set:function(b){this.abrController.nextAutoLevel=Math.max(this.minAutoLevel,b)}},{key:"audioTracks",get:function(){var b=this.audioTrackController;return b?b.audioTracks:[]}},{key:"audioTrack",get:function(){var b=this.audioTrackController; return b?b.audioTrack:-1},set:function(b){var c=this.audioTrackController;c&&(c.audioTrack=b)}},{key:"subtitleTracks",get:function(){var b=this.subtitleTrackController;return b?b.subtitleTracks:[]}},{key:"subtitleTrack",get:function(){var b=this.subtitleTrackController;return b?b.subtitleTrack:-1},set:function(b){var c=this.subtitleTrackController;c&&(c.subtitleTrack=b)}},{key:"media",get:function(){return this._media}},{key:"subtitleDisplay",get:function(){var b=this.subtitleTrackController;return!!b&& b.subtitleDisplay},set:function(b){var c=this.subtitleTrackController;c&&(c.subtitleDisplay=b)}},{key:"lowLatencyMode",get:function(){return this.config.lowLatencyMode},set:function(b){this.config.lowLatencyMode=b}},{key:"liveSyncPosition",get:function(){return this.latencyController.liveSyncPosition}},{key:"latency",get:function(){return this.latencyController.latency}},{key:"maxLatency",get:function(){return this.latencyController.maxLatency}},{key:"targetLatency",get:function(){return this.latencyController.targetLatency}}, {key:"drift",get:function(){return this.latencyController.drift}},{key:"forceStartLoad",get:function(){return this.streamController.forceStartLoad}}],Qa(b.prototype,c),d&&Qa(b,d),b}();td.defaultConfig=void 0}])["default"]})}(window,U,B),U.exports&&(ea.hls=U.exports)}catch(K){console.error(K)}}window.bradmax||(window.bradmax={});window.bradmax.jsdependency||(window.bradmax.jsdependency={});if(!window.bradmax.jsdependency.js_ae322d44547c32073185463ba706378c){window.bradmax.jsdependency.js_ae322d44547c32073185463ba706378c= !0;try{U={},function(B,x,k){(function(k){var p=k.dashjs,x={skipAutoCreate:!0};k.dashjs=x;!function g(k,l,h){function e(b,c){if(!l[b]){if(!k[b]){var d="function"==typeof require&&require;if(!c&&d)return d(b,!0);if(f)return f(b,!0);d=Error("Cannot find module '"+b+"'");throw d.code="MODULE_NOT_FOUND",d;}d=l[b]={exports:{}};k[b][0].call(d.exports,function(c){return e(k[b][1][c]||c)},d,d.exports,g,k,l,h)}return l[b].exports}for(var f="function"==typeof require&&require,d=0;d>18));d.push(f.charAt(63&g>>12));d.push(f.charAt(63&g>>6));d.push(f.charAt(63&g))}return 2==b.length-c?(g=(b[c]<<16)+(b[c+1]<<8),d.push(f.charAt(63&g>>18)),d.push(f.charAt(63&g>>12)),d.push(f.charAt(63&g>>6)),d.push("=")):1==b.length-c&&(g=b[c]<<16,d.push(f.charAt(63&g>>18)),d.push(f.charAt(63&g>>12)),d.push("==")),d.join("")}function e(b){for(var c=0,e=[],f=0|b.length/4;0>16);e.push(255&g>>8);e.push(255&g);c+=4}return e&&("="==b.charAt(c-2)?(e.pop(),e.pop()):"="==b.charAt(c-1)&&e.pop()),e}var f,d,b,c={encode:function(b){for(var c=[],d=0;de?c.push(e):(2048>e?c.push(192|e>>6):(65536>e?c.push(224|e>>12):(c.push(240|e>>18),c.push(128|63&e>>12)),c.push(128|63&e>>6)),c.push(128|63&e))}return c},decode:function(b){for(var c= [],d=0;de||(224>e?e=(31&e)<<6:(240>e?e=(15&e)<<12:(e=(7&e)<<18,e|=(63&b[d++])<<12),e|=(63&b[d++])<<6),e|=63&b[d++]);c.push(String.fromCharCode(e))}return c.join("")}},m,n;f="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";d=function(){for(var b=[],c=0;cc;c++)this.chars.push(new b);this.pos=0;this.currPenState=new d}function m(){this.rows=[];for(var b=0;15>b;b++)this.rows.push(new c);this.currRow=14;this.nrRollUpRows=null;this.reset()}function h(b,c){this.chNr=b;this.outputFilter=c;this.mode=null;this.verbose=0;this.displayedMemory=new m;this.nonDisplayedMemory= new m;this.lastOutputScreen=new m;this.currRollUpRow=this.displayedMemory.rows[14];this.writeScreen=this.displayedMemory;this.cueStartTime=this.mode=null}function q(b,c,d){this.field=b||1;this.outputs=[c,d];this.channels=[new h(1,c),new h(2,d)];this.currChNr=-1;this.lastCmdB=this.lastCmdA=null;this.bufferedData=[];this.lastTime=this.startTime=null;this.dataCounters={padding:0,"char":0,cmd:0,other:0}}var k={42:225,92:233,94:237,95:243,96:250,123:231,124:247,125:209,126:241,127:9608,128:174,129:176, 130:189,131:191,132:8482,133:162,134:163,135:9834,136:224,137:32,138:232,139:226,140:234,141:238,142:244,143:251,144:193,145:201,146:211,147:218,148:220,149:252,150:8216,151:161,152:42,153:8217,154:9473,155:169,156:8480,157:8226,158:8220,159:8221,160:192,161:194,162:199,163:200,164:202,165:203,166:235,167:206,168:207,169:239,170:212,171:217,172:249,173:219,174:171,175:187,176:195,177:227,178:205,179:204,180:236,181:210,182:242,183:213,184:245,185:123,186:125,187:92,188:94,189:95,190:124,191:8764, 192:196,193:228,194:214,195:246,196:223,197:165,198:164,199:9475,200:197,201:229,202:216,203:248,204:9487,205:9491,206:9495,207:9499},l={17:1,18:3,21:5,22:7,23:9,16:11,19:12,20:14},z={17:2,18:4,21:6,22:8,23:10,19:13,20:15},Q={25:1,26:3,29:5,30:7,31:9,24:11,27:12,28:14},X={25:2,26:4,29:6,30:8,31:10,27:13,28:15},N="white green blue cyan red yellow magenta black transparent".split(" "),D={verboseFilter:{DATA:3,DEBUG:3,INFO:2,WARNING:2,TEXT:1,ERROR:0},time:null,verboseLevel:0,setTime:function(b){this.time= b},log:function(b,c){this.verboseLevel>=this.verboseFilter[b]&&console.log(this.time+" ["+b+"] "+c)}};d.prototype={reset:function(){this.foreground="white";this.italics=this.underline=!1;this.background="black";this.flash=!1},setStyles:function(b){for(var c=["foreground","underline","italics","background","flash"],d=0;dd;d++)if(!this.chars[d].equals(b.chars[d])){c=!1;break}return c},copy:function(b){for(var c=0;32> c;c++)this.chars[c].copy(b.chars[c])},isEmpty:function(){for(var b=!0,c=0;32>c;c++)if(!this.chars[c].isEmpty()){b=!1;break}return b},setCursor:function(b){this.pos!==b&&(this.pos=b);0>this.pos?(D.log("ERROR","Negative cursor position "+this.pos),this.pos=0):32b;b++)this.chars[b].reset()},clear:function(){this.clearFromPos(0);this.pos=0;this.currPenState.reset()},clearToEndOfRow:function(){this.clearFromPos(this.pos)},getTextString:function(){for(var b= [],c=!0,d=0;32>d;d++){var e=this.chars[d].uchar;" "!==e&&(c=!1);b.push(e)}return c?"":b.join("")},setPenStyles:function(b){this.currPenState.setStyles(b);this.chars[this.pos].setPenState(this.currPenState)}};m.prototype={reset:function(){for(var b=0;15>b;b++)this.rows[b].clear();this.currRow=14},equals:function(b){for(var c=!0,d=0;15>d;d++)if(!this.rows[d].equals(b.rows[d])){c=!1;break}return c},copy:function(b){for(var c=0;15>c;c++)this.rows[c].copy(b.rows[c])},isEmpty:function(){for(var b=!0,c= 0;15>c;c++)if(!this.rows[c].isEmpty()){b=!1;break}return b},backSpace:function(){this.rows[this.currRow].backSpace()},clearToEndOfRow:function(){this.rows[this.currRow].clearToEndOfRow()},insertChar:function(b){this.rows[this.currRow].insertChar(b)},setPen:function(b){this.rows[this.currRow].setPenStyles(b)},moveCursor:function(b){this.rows[this.currRow].moveCursor(b)},setCursor:function(b){D.log("INFO","setCursor: "+b);this.rows[this.currRow].setCursor(b)},setPAC:function(b){D.log("INFO","pacData = "+ JSON.stringify(b));var c=b.row-1;this.nrRollUpRows&&cf;f++){var g=this.rows[f].getTextString();g&&(e=f+1,b?c.push("Row "+e+': "'+g+'"'):c.push(g.trim()))}return 0=m&&m===this.lastCmdA&&h===this.lastCmdB?(this.lastCmdA=null,this.lastCmdB=null,D.log("DEBUG","Repeated command ("+f([m,h])+") is dropped")):0!=m||0!=h?(D.log("DATA","["+f([c[g],c[g+1]])+"] -> ("+f([m,h])+")"),(d=(d=(d=(d=this.parseCmd(m,h))||this.parseMidrow(m,h))||this.parsePAC(m,h))||this.parseBackgroundAttributes(m,h))||(e=this.parseChars(m,h))&&(this.currChNr&&0<=this.currChNr?this.channels[this.currChNr-1].insertChars(e):D.log("WARNING","No channel found yet. TEXT-MODE?")),d?this.dataCounters.cmd+= 2:e?this.dataCounters["char"]+=2:(this.dataCounters.other+=2,D.log("WARNING","Couldn't parse cleaned data "+f([m,h])+" orig: "+f([c[g],c[g+1]])))):this.dataCounters.padding+=2}},parseCmd:function(b,c){var d;if(!((20===b||21===b||28===b||29===b)&&32<=c&&47>=c||(23===b||31===b)&&33<=c&&35>=c))return!1;d=20===b||21===b||23===b?1:2;var e=this.channels[d-1];return 20===b||21===b||28===b||29===b?32===c?e.cc_RCL():33===c?e.cc_BS():34===c?e.cc_AOF():35===c?e.cc_AON():36===c?e.cc_DER():37===c?e.cc_RU(2):38=== c?e.cc_RU(3):39===c?e.cc_RU(4):40===c?e.cc_FON():41===c?e.cc_RDC():42===c?e.cc_TR():43===c?e.cc_RTD():44===c?e.cc_EDM():45===c?e.cc_CR():46===c?e.cc_ENM():47===c&&e.cc_EOC():e.cc_TO(c-32),this.lastCmdA=b,this.lastCmdB=c,this.currChNr=d,!0},parseMidrow:function(b,c){var d;if((17===b||25===b)&&32<=c&&47>=c){if((d=17===b?1:2)!==this.currChNr)return D.log("ERROR","Mismatch channel in midrow parsing"),!1;d=this.channels[d-1];return d.insertChars([32]),d.cc_MIDROW(c),D.log("DEBUG","MIDROW ("+f([b,c])+")"), this.lastCmdA=b,this.lastCmdB=c,!0}return!1},parsePAC:function(b,c){var d;if(!((17<=b&&23>=b||25<=b&&31>=b)&&64<=c&&127>=c||(16===b||24===b)&&64<=c&&95>=c))return!1;d=23>=b?1:2;var e=this.interpretPAC(64<=c&&95>=c?1==d?l[b]:Q[b]:1==d?z[b]:X[b],c);return this.channels[d-1].setPAC(e),this.lastCmdA=b,this.lastCmdB=c,this.currChNr=d,!0},interpretPAC:function(b,c){var d,e={color:null,italics:!1,indent:null,underline:!1,row:b};d=95=d?e.color="white green blue cyan red yellow magenta white".split(" ")[Math.floor(d/ 2)]:15>=d?(e.italics=!0,e.color="white"):e.indent=4*Math.floor((d-16)/2),e},parseChars:function(b,c){var d,g,m=null,h=null,n=null;return 17<=(n=25<=b?(m=2,b-8):(m=1,b))&&19>=n?(d=17===n?c+80:18===n?c+112:c+144,D.log("INFO","Special char '"+e(d)+"' in channel "+m),h=[d],this.lastCmdA=b,this.lastCmdB=c):32<=b&&127>=b&&(h=0===c?[b]:[b,c],this.lastCmdA=null,this.lastCmdB=null),h&&(g=f(h),D.log("DEBUG","Char codes = "+g.join(","))),h},parseBackgroundAttributes:function(b,c){var d,e,f;return((16===b|| 24===b)&&32<=c&&47>=c||(23===b||31===b)&&45<=c&&47>=c)&&(d={},16===b||24===b?(e=Math.floor((c-32)/2),d.background=N[e],1==c%2&&(d.background+="_semi")):45===c?d.background="transparent":(d.foreground="black",47===c&&(d.underline=!0)),f=24>b?1:2,this.channels[f-1].setBkgData(d),this.lastCmdA=b,this.lastCmdB=c,!0)},reset:function(){for(var b=0;br)n=null;else{h=n.getUint8(k);var q=n.getUint16(k+1),w=n.getUint32(k+3),n=n.getUint8(k+7),n=181==h&&49==q&&1195456820==w&&3==n}!n||g.push([m,r]);m+= r}f+=e+4}return g};g.extractCea608DataFromRange=function(b,c){for(var d=c[0],e=[[],[]],d=d+8,f=31&b.getUint8(d),d=d+2,g=0;g/g,">").replace(/"/g,""").replace(/'/g,"'"):b}function d(b,c,d,e){for(var f=0;f":">")}function q(b,c){return""}function w(b,c){return"property"==g.arrayAccessForm&&(d=c.toString(),e= "_asArray",-1!==d.indexOf(e,d.length-e.length))||0==c.toString().indexOf(g.attributePrefix)||0==c.toString().indexOf("__")||b[c]instanceof Function;var d,e}function l(b){var c=0;if(b instanceof Object)for(var d in b)w(b,d)||c++;return c}function z(b){var c=[];if(b instanceof Object)for(var d in b)-1==d.toString().indexOf("__")&&0==d.toString().indexOf(g.attributePrefix)&&c.push(d);return c}function Q(b){var c,d="";return b instanceof Object?d+=(c="",null!=b.__cdata&&(c+="")+2)),(c=new ActiveXObject("Microsoft.XMLDOM")).async="false",c.loadXML(b);return c};this.asArray=function(b){return void 0===b||null==b?[]:b instanceof Array?b:[b]};this.toXmlDateTime= function(b){return b instanceof Date?b.toISOString():"number"==typeof b?(new Date(b)).toISOString():null};this.asDateTime=function(b){return"string"==typeof b?c(b):b};this.xml2json=function(b){return m(b)};this.xml_str2json=function(b){b=this.parseXmlString(b);return null!=b?this.xml2json(b):null};this.json2xml_str=function(b){return X(b,"")};this.json2xml=function(b){b=this.json2xml_str(b);return this.parseXmlString(b)};this.getVersion=function(){return"1.2.0"}};y.exports=l["default"]},{}],4:[function(g, k,l){function h(b){return b&&b.__esModule?b:{"default":b}}Object.defineProperty(l,"__esModule",{value:!0});k=g(5);var e=h(g(124)),f=h(g(161)),d=h(g(102));g=h(g(45));x.Protection=f["default"];x.MetricsReporting=e["default"];x.MediaPlayerFactory=d["default"];x.Debug=g["default"];l["default"]=x;l.MediaPlayer=k.MediaPlayer;l.Protection=f["default"];l.MetricsReporting=e["default"];l.MediaPlayerFactory=d["default"];l.Debug=g["default"]},{102:102,124:124,161:161,45:45,5:5}],5:[function(g,y,l){(function(h){function e(b){return b&& b.__esModule?b:{"default":b}}Object.defineProperty(l,"__esModule",{value:!0});var f=e(g(100)),d=e(g(47)),b=e(g(45)),c=g(50);h="undefined"!=typeof k&&k||h;var m=h.dashjs;(m=m||(h.dashjs={})).MediaPlayer=f["default"];m.FactoryMaker=d["default"];m.Debug=b["default"];m.Version=(0,c.getVersionString)();l["default"]=m;l.MediaPlayer=f["default"];l.FactoryMaker=d["default"];l.Debug=b["default"]}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof k?k:{})},{100:100, 45:45,47:47,50:50}],6:[function(g,k,l){function h(b){var c=b.length;if(0>16&255,k[w++]=c>>8&255,k[w++]= 255&c;2===e&&(c=f[b.charCodeAt(l)]<<2|f[b.charCodeAt(l+1)]>>4,k[w++]=255&c);1===e&&(c=f[b.charCodeAt(l)]<<10|f[b.charCodeAt(l+1)]<<4|f[b.charCodeAt(l+2)]>>2,k[w++]=c>>8&255,k[w++]=255&c);return k};l.fromByteArray=function(b){for(var c,d=b.length,f=d%3,g=[],h=0,k=d-f;h>18&63]+e[c>>12&63]+e[c>>6&63]+e[63&c]);return f.join("")}(b,h,k> 2]+e[c<<4&63]+"==")):2==f&&(c=(b[d-2]<<8)+b[d-1],g.push(e[c>>10]+e[c>>4&63]+e[c<<2&63]+"="));return g.join("")};var e=[],f=[],d="undefined"!=typeof Uint8Array?Uint8Array:Array;for(g=0;64>g;++g)e[g]="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"[g],f["ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charCodeAt(g)]=g;f[45]=62;f[95]=63},{}],7:[function(g,k,l){},{}],8:[function(g,k,l){function h(b){if(rc||b.byteLengthb)throw new RangeError('The value "'+b+'" is invalid for option "size"');}function b(b){return d(b),h(0>b?0:0|m(b))}function c(b){for(var c= 0>b.length?0:0|m(b.length),d=h(c),e=0;e>>1;case "base64":return T(b).length;default:if(g)return f?-1:P(b).length;c=(""+c).toLowerCase();g=!0}}function q(b,c,d){var e,f,g=!1;if(((void 0===c||0>c)&&(c=0),c>this.length)||((void 0===d||d>this.length)&&(d=this.length),0>=d)||(d>>>=0)<=(c>>>=0))return""; for(b=b||"utf8";;)switch(b){case "hex":return function(b,c,d){var e=b.length;(!c||0>c)&&(c=0);(!d||0>d||ef?"0"+f.toString(16):f.toString(16);e+=f}return e}(this,c,d);case "utf8":case "utf-8":return X(this,c,d);case "ascii":return function(b,c,d){var e="";for(d=Math.min(b.length,d);cd&&(d=-2147483648);var m=d=+d;if(m!=m&&(d=g?0:b.length-1),0>d&&(d=b.length+d),d>=b.length){if(g)return-1;d=b.length-1}else if(0>d){if(!g)return-1;d=0}if("string"==typeof c&&(c=e.from(c,f)),e.isBuffer(c))return 0===c.length?-1:z(b,c,d,f,g);if("number"==typeof c)return c&=255,"function"==typeof Uint8Array.prototype.indexOf?g?Uint8Array.prototype.indexOf.call(b,c,d):Uint8Array.prototype.lastIndexOf.call(b,c,d):z(b,[c],d,f,g);throw new TypeError("val must be string, number or Buffer"); }function z(b,c,d,e,f){function g(b,c){return 1===m?b[c]:b.readUInt16BE(c*m)}var m=1,n=b.length,h=c.length;if(void 0!==e&&("ucs2"===(e=String(e).toLowerCase())||"ucs-2"===e||"utf16le"===e||"utf-16le"===e)){if(2>b.length||2>c.length)return-1;n/=m=2;h/=2;d/=2}if(f)for(e=-1;dh&&(v=h);break;case 2:128==(192&(f=b[c+1]))&&127<(n=(31&h)<<6|63&f)&&(v=n);break;case 3:f=b[c+1];g=b[c+2];128==(192&f)&&128==(192&g)&&2047<(n=(15&h)<<12|(63&f)<<6|63&g)&&(55296>n||57343n&&(v=n)}null===v?(v=65533,k=1):65535>>10&1023|55296),v=56320|1023&v);e.push(v);c+=k}b=e.length;if(b<=E)e=String.fromCharCode.apply(String,e);else{d="";for(f=0;fb)throw new RangeError("offset is not uint");if(db.length)throw new RangeError("Index out of range");}function Y(b,c,d,e){if(d+e>b.length)throw new RangeError("Index out of range");if(0>d)throw new RangeError("Index out of range");}function y(b,c,d,e,f){return c=+c,d>>>=0,f||Y(b,0,d,4),C.write(b,c,d,e,23,4),d+4}function u(b,c,d,e,f){return c=+c,d>>>=0,f||Y(b,0,d,8),C.write(b,c,d,e,52,8),d+8}function P(b,c){var d;c=c||1/0;for(var e=b.length,f=null,g=[],m=0;md){if(!f){if(56319d){-1<(c-=3)&&g.push(239,191,189);f=d;continue}d=65536+(f-55296<<10|d-56320)}else f&&-1<(c-=3)&&g.push(239,191,189);if(f=null,128>d){if(0>--c)break;g.push(d)}else if(2048>d){if(0>(c-=2))break;g.push(d>>6|192,63&d|128)}else if(65536>d){if(0>(c-=3))break;g.push(d>>12|224,d>>6&63|128,63&d|128)}else{if(!(1114112>d))throw Error("Invalid code point"); if(0>(c-=4))break;g.push(d>>18|240,d>>12&63|128,d>>6&63|128,63&d|128)}}return g}function T(b){return t.toByteArray(function(b){if(2>(b=(b=b.split("=")[0]).trim().replace(L,"")).length)return"";for(;0!=b.length%4;)b+="=";return b}(b))}function O(b,c,d,e){for(var f=0;f=c.length||f>=b.length);++f)c[f+d]=b[f];return f}function F(b,c){return b instanceof c||null!=b&&null!=b.constructor&&null!=b.constructor.name&&b.constructor.name===c.name}var t=g(6),C=g(13);l.Buffer=e;l.SlowBuffer=function(b){+b!= b&&(b=0);return e.alloc(+b)};l.INSPECT_MAX_BYTES=50;var r=2147483647;l.kMaxLength=r;(e.TYPED_ARRAY_SUPPORT=function(){try{var b=new Uint8Array(1);return b.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},42===b.foo()}catch(G){return!1}}())||"undefined"==typeof console||"function"!=typeof console.error||console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");Object.defineProperty(e.prototype, "parent",{enumerable:!0,get:function(){if(e.isBuffer(this))return this.buffer}});Object.defineProperty(e.prototype,"offset",{enumerable:!0,get:function(){if(e.isBuffer(this))return this.byteOffset}});"undefined"!=typeof Symbol&&null!=Symbol.species&&e[Symbol.species]===e&&Object.defineProperty(e,Symbol.species,{value:null,configurable:!0,enumerable:!1,writable:!1});e.poolSize=8192;e.from=f;e.prototype.__proto__=Uint8Array.prototype;e.__proto__=Uint8Array;e.alloc=function(b,c,e){return g=c,m=e,d(f= b),0>=f||void 0===g?h(f):"string"==typeof m?h(f).fill(g,m):h(f).fill(g);var f,g,m};e.allocUnsafe=b;e.allocUnsafeSlow=b;e.isBuffer=function(b){return null!=b&&!0===b._isBuffer&&b!==e.prototype};e.compare=function(b,c){if(F(b,Uint8Array)&&(b=e.from(b,b.offset,b.byteLength)),F(c,Uint8Array)&&(c=e.from(c,c.offset,c.byteLength)),!e.isBuffer(b)||!e.isBuffer(c))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(b===c)return 0;for(var d=b.length,f=c.length,g=0, m=Math.min(d,f);gc&&(b+=" ... "),""};e.prototype.compare=function(b,c,d,f,g){if(F(b,Uint8Array)&&(b=e.from(b,b.offset,b.byteLength)),!e.isBuffer(b))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof b);if(void 0===c&&(c=0),void 0===d&&(d=b?b.length:0),void 0===f&&(f=0), void 0===g&&(g=this.length),0>c||d>b.length||0>f||g>this.length)throw new RangeError("out of range index");if(g<=f&&d<=c)return 0;if(g<=f)return-1;if(d<=c)return 1;if(this===b)return 0;var m=(g>>>=0)-(f>>>=0),n=(d>>>=0)-(c>>>=0),h=Math.min(m,n);f=this.slice(f,g);b=b.slice(c,d);for(c=0;c>>=0;isFinite(d)?(d>>>=0,void 0===e&&(e="utf8")):(e=d,d=void 0)}var f=this.length-c;if((void 0===d||fd||0>c)||c>this.length)throw new RangeError("Attempt to write outside buffer bounds"); e=e||"utf8";for(var g,m,n,h,f=!1;;)switch(e){case "hex":a:{c=Number(c)||0;e=this.length-c;(!d||e<(d=Number(d)))&&(d=e);e=b.length;e/2(e-=2));++n)h=b.charCodeAt(n),g=h>>8,h%=256,m.push(h),m.push(g);return O(m,this,c,d);default:if(f)throw new TypeError("Unknown encoding: "+e);e=(""+e).toLowerCase();f=!0}};e.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var E=4096;e.prototype.slice=function(b,c){var d=this.length;0>(b=~~b)?0>(b+=d)&&(b=0):d(c=void 0===c?d:~~c)?0>(c+=d)&&(c=0):d>>=0;c>>>=0;d||N(b,c,this.length);d=this[b];for(var e=1,f=0;++f>>=0;c>>>=0;d||N(b,c,this.length);d=this[b+--c];for(var e=1;0>>=0,c||N(b,1,this.length),this[b]};e.prototype.readUInt16LE=function(b,c){return b>>>=0,c||N(b,2,this.length),this[b]|this[b+1]<<8};e.prototype.readUInt16BE= function(b,c){return b>>>=0,c||N(b,2,this.length),this[b]<<8|this[b+1]};e.prototype.readUInt32LE=function(b,c){return b>>>=0,c||N(b,4,this.length),(this[b]|this[b+1]<<8|this[b+2]<<16)+16777216*this[b+3]};e.prototype.readUInt32BE=function(b,c){return b>>>=0,c||N(b,4,this.length),16777216*this[b]+(this[b+1]<<16|this[b+2]<<8|this[b+3])};e.prototype.readIntLE=function(b,c,d){b>>>=0;c>>>=0;d||N(b,c,this.length);d=this[b];for(var e=1,f=0;++f>>=0;c>>>=0;d||N(b,c,this.length);d=c;for(var e=1,f=this[b+--d];0>>=0,c||N(b,1,this.length),128&this[b]?-1*(255-this[b]+1):this[b]};e.prototype.readInt16LE=function(b,c){b>>>=0;c||N(b,2,this.length);var d=this[b]|this[b+1]<<8;return 32768&d?4294901760|d:d};e.prototype.readInt16BE=function(b,c){b>>>=0;c||N(b,2,this.length);var d=this[b+1]| this[b]<<8;return 32768&d?4294901760|d:d};e.prototype.readInt32LE=function(b,c){return b>>>=0,c||N(b,4,this.length),this[b]|this[b+1]<<8|this[b+2]<<16|this[b+3]<<24};e.prototype.readInt32BE=function(b,c){return b>>>=0,c||N(b,4,this.length),this[b]<<24|this[b+1]<<16|this[b+2]<<8|this[b+3]};e.prototype.readFloatLE=function(b,c){return b>>>=0,c||N(b,4,this.length),C.read(this,b,!0,23,4)};e.prototype.readFloatBE=function(b,c){return b>>>=0,c||N(b,4,this.length),C.read(this,b,!1,23,4)};e.prototype.readDoubleLE= function(b,c){return b>>>=0,c||N(b,8,this.length),C.read(this,b,!0,52,8)};e.prototype.readDoubleBE=function(b,c){return b>>>=0,c||N(b,8,this.length),C.read(this,b,!1,52,8)};e.prototype.writeUIntLE=function(b,c,d,e){b=+b;c>>>=0;d>>>=0;e||D(this,b,c,d,Math.pow(2,8*d)-1,0);e=1;var f=0;for(this[c]=255&b;++f>>=0;d>>>=0;e||D(this,b,c,d,Math.pow(2,8*d)-1,0);e=d-1;var f=1;for(this[c+e]=255&b;0<=--e&&(f*=256);)this[c+ e]=b/f&255;return c+d};e.prototype.writeUInt8=function(b,c,d){return b=+b,c>>>=0,d||D(this,b,c,1,255,0),this[c]=255&b,c+1};e.prototype.writeUInt16LE=function(b,c,d){return b=+b,c>>>=0,d||D(this,b,c,2,65535,0),this[c]=255&b,this[c+1]=b>>>8,c+2};e.prototype.writeUInt16BE=function(b,c,d){return b=+b,c>>>=0,d||D(this,b,c,2,65535,0),this[c]=b>>>8,this[c+1]=255&b,c+2};e.prototype.writeUInt32LE=function(b,c,d){return b=+b,c>>>=0,d||D(this,b,c,4,4294967295,0),this[c+3]=b>>>24,this[c+2]=b>>>16,this[c+1]=b>>> 8,this[c]=255&b,c+4};e.prototype.writeUInt32BE=function(b,c,d){return b=+b,c>>>=0,d||D(this,b,c,4,4294967295,0),this[c]=b>>>24,this[c+1]=b>>>16,this[c+2]=b>>>8,this[c+3]=255&b,c+4};e.prototype.writeIntLE=function(b,c,d,e){var f;b=+b;c>>>=0;e||D(this,b,c,d,(f=Math.pow(2,8*d-1))-1,-f);e=0;f=1;var g=0;for(this[c]=255&b;++eb&&0===g&&0!==this[c+e-1]&&(g=1),this[c+e]=(b/f>>0)-g&255;return c+d};e.prototype.writeIntBE=function(b,c,d,e){var f;b=+b;c>>>=0;e||D(this,b,c,d,(f=Math.pow(2,8*d-1))- 1,-f);e=d-1;f=1;var g=0;for(this[c+e]=255&b;0<=--e&&(f*=256);)0>b&&0===g&&0!==this[c+e+1]&&(g=1),this[c+e]=(b/f>>0)-g&255;return c+d};e.prototype.writeInt8=function(b,c,d){return b=+b,c>>>=0,d||D(this,b,c,1,127,-128),0>b&&(b=255+b+1),this[c]=255&b,c+1};e.prototype.writeInt16LE=function(b,c,d){return b=+b,c>>>=0,d||D(this,b,c,2,32767,-32768),this[c]=255&b,this[c+1]=b>>>8,c+2};e.prototype.writeInt16BE=function(b,c,d){return b=+b,c>>>=0,d||D(this,b,c,2,32767,-32768),this[c]=b>>>8,this[c+1]=255&b,c+2}; e.prototype.writeInt32LE=function(b,c,d){return b=+b,c>>>=0,d||D(this,b,c,4,2147483647,-2147483648),this[c]=255&b,this[c+1]=b>>>8,this[c+2]=b>>>16,this[c+3]=b>>>24,c+4};e.prototype.writeInt32BE=function(b,c,d){return b=+b,c>>>=0,d||D(this,b,c,4,2147483647,-2147483648),0>b&&(b=4294967295+b+1),this[c]=b>>>24,this[c+1]=b>>>16,this[c+2]=b>>>8,this[c+3]=255&b,c+4};e.prototype.writeFloatLE=function(b,c,d){return y(this,b,c,!0,d)};e.prototype.writeFloatBE=function(b,c,d){return y(this,b,c,!1,d)};e.prototype.writeDoubleLE= function(b,c,d){return u(this,b,c,!0,d)};e.prototype.writeDoubleBE=function(b,c,d){return u(this,b,c,!1,d)};e.prototype.copy=function(b,c,d,f){if(!e.isBuffer(b))throw new TypeError("argument should be a Buffer");if((d=d||0,f||0===f||(f=this.length),c>=b.length&&(c=b.length),c=c||0,0c)throw new RangeError("targetStart out of bounds");if(0>d||d>=this.length)throw new RangeError("Index out of range");if(0>f)throw new RangeError("sourceEnd out of bounds"); f>this.length&&(f=this.length);b.length-cg||"latin1"===f)&&(b=g))}else"number"==typeof b&&(b&=255);if(0>c||this.length>>=0,d=void 0===d?this.length:d>>>0,"number"==typeof(b=b||0))for(f=c;fc||(224>c?c=(31&c)<<6:(240>c?c=(15&c)<<12:(c=(7&c)<<18,c|=(63&d.getUint8(f++))<<12),c|=(63&d.getUint8(f++))<<6),c|=63&d.getUint8(f++)),e.push(String.fromCharCode(c));else for(;fe?b.push(e):(2048>e?b.push(192|e>>6):(65536>e?b.push(224|e>>12):(b.push(240|e>>18),b.push(128|63&e>>12)),b.push(128|63&e>>6)),b.push(128|63&e))}return b};h.Utils.appendBox=function(d,b,c){if(b._offset=d._cursor.offset,b._root=d._root?d._root:d,b._raw=d._raw,b._parent=d,-1!==c)if(null!=c){var e=-1;if("number"==typeof c)e=c;else{if("string"!=typeof c){if("object"!=typeof c||!c.type)return void d.boxes.push(b);c=c.type}for(var f=0;f>3,b};f.prototype._readUint=function(d){var b,c;b=null;c=this._cursor.offset-this._raw.byteOffset;switch(d){case 8:b=this._raw.getUint8(c);break;case 16:b=this._raw.getUint16(c); break;case 24:b=(this._raw.getUint16(c)<<8)+this._raw.getUint8(2+c);break;case 32:b=this._raw.getUint32(c);break;case 64:b=this._raw.getUint32(c),c=this._raw.getUint32(4+c),b=b*Math.pow(2,32)+c}return this._cursor.offset+=d>>3,b};f.prototype._readString=function(d){for(var b="",c=0;cthis._raw.buffer.byteLength)this._root._incomplete=!0;else{switch(this._procField("size","uint",32),this._procField("type","string",4),1===this.size&&this._procField("largesize","uint",64),"uuid"===this.type&&this._procFieldArray("usertype",16,"uint",8),this.size){case 0:this._raw=new DataView(this._raw.buffer,this._offset,this._raw.byteLength- this._cursor.offset+8);break;case 1:this._offset+this.size>this._raw.buffer.byteLength?(this._incomplete=!0,this._root._incomplete=!0):this._raw=new DataView(this._raw.buffer,this._offset,this.largesize);break;default:this._offset+this.size>this._raw.buffer.byteLength?(this._incomplete=!0,this._root._incomplete=!0):this._raw=new DataView(this._raw.buffer,this._offset,this.size)}this._incomplete||(this._boxProcessors[this.type]&&this._boxProcessors[this.type].call(this),-1!==this._boxContainers.indexOf(this.type)? this._parseContainerBox():this._data=this._readData())}};f.prototype._parseFullBox=function(){this.version=this._readUint(8);this.flags=this._readUint(24)};f.prototype._parseContainerBox=function(){for(this.boxes=[];this._cursor.offset-this._raw.byteOffset>3}else this.size+=d>>3};f.prototype._writeUint=function(d,b){if(this._rawo){var c,e,f=this._cursor.offset-this._rawo.byteOffset;switch(d){case 8:this._rawo.setUint8(f,b);break;case 16:this._rawo.setUint16(f,b);break;case 24:e=255&b;this._rawo.setUint16(f,(16776960&b)>>8);this._rawo.setUint8(2+f,e);break;case 32:this._rawo.setUint32(f,b);break;case 64:e=b-(c=Math.floor(b/Math.pow(2,32)))*Math.pow(2, 32),this._rawo.setUint32(f,c),this._rawo.setUint32(4+f,e)}this._cursor.offset+=d>>3}else this.size+=d>>3};f.prototype._writeString=function(d,b){for(var c=0;c>10&31),96+(this.language>>5&31),96+(31&this.language)));this._procField("pre_defined","uint",16)};f.prototype._boxProcessors.mehd=function(){this._procFullBox();this._procField("fragment_duration","uint",1==this.version?64:32)};f.prototype._boxProcessors.mfhd=function(){this._procFullBox();this._procField("sequence_number","uint",32)};f.prototype._boxProcessors.mfro=function(){this._procFullBox();this._procField("mfra_size","uint",32)};f.prototype._boxProcessors.mp4a=f.prototype._boxProcessors.enca= function(){this._procFieldArray("reserved1",6,"uint",8);this._procField("data_reference_index","uint",16);this._procFieldArray("reserved2",2,"uint",32);this._procField("channelcount","uint",16);this._procField("samplesize","uint",16);this._procField("pre_defined","uint",16);this._procField("reserved3","uint",16);this._procField("samplerate","template",32);this._procField("esds","data",-1)};f.prototype._boxProcessors.mvhd=function(){this._procFullBox();this._procField("creation_time","uint",1==this.version? 64:32);this._procField("modification_time","uint",1==this.version?64:32);this._procField("timescale","uint",32);this._procField("duration","uint",1==this.version?64:32);this._procField("rate","template",32);this._procField("volume","template",16);this._procField("reserved1","uint",16);this._procFieldArray("reserved2",2,"uint",32);this._procFieldArray("matrix",9,"template",32);this._procFieldArray("pre_defined",6,"uint",32);this._procField("next_track_ID","uint",32)};f.prototype._boxProcessors.payl= function(){this._procField("cue_text","utf8")};f.prototype._boxProcessors.pssh=function(){this._procFullBox();this._procFieldArray("SystemID",16,"uint",8);this._procField("DataSize","uint",32);this._procFieldArray("Data",this.DataSize,"uint",8)};f.prototype._boxProcessors.schm=function(){this._procFullBox();this._procField("scheme_type","uint",32);this._procField("scheme_version","uint",32);1&this.flags&&this._procField("scheme_uri","string",-1)};f.prototype._boxProcessors.sdtp=function(){this._procFullBox(); var d=-1;this._parsing&&(d=this._raw.byteLength-(this._cursor.offset-this._raw.byteOffset));this._procFieldArray("sample_dependency_table",d,"uint",8)};f.prototype._boxProcessors.sidx=function(){this._procFullBox();this._procField("reference_ID","uint",32);this._procField("timescale","uint",32);this._procField("earliest_presentation_time","uint",1==this.version?64:32);this._procField("first_offset","uint",1==this.version?64:32);this._procField("reserved","uint",16);this._procField("reference_count", "uint",16);this._procEntries("references",this.reference_count,function(d){this._parsing||(d.reference=(1&d.reference_type)<<31,d.reference|=2147483647&d.referenced_size,d.sap=(1&d.starts_with_SAP)<<31,d.sap|=(3&d.SAP_type)<<28,d.sap|=268435455&d.SAP_delta_time);this._procEntryField(d,"reference","uint",32);this._procEntryField(d,"subsegment_duration","uint",32);this._procEntryField(d,"sap","uint",32);this._parsing&&(d.reference_type=d.reference>>31&1,d.referenced_size=2147483647&d.reference,d.starts_with_SAP= d.sap>>31&1,d.SAP_type=d.sap>>28&7,d.SAP_delta_time=268435455&d.sap)})};f.prototype._boxProcessors.smhd=function(){this._procFullBox();this._procField("balance","uint",16);this._procField("reserved","uint",16)};f.prototype._boxProcessors.ssix=function(){this._procFullBox();this._procField("subsegment_count","uint",32);this._procEntries("subsegments",this.subsegment_count,function(d){this._procEntryField(d,"ranges_count","uint",32);this._procSubEntries(d,"ranges",d.ranges_count,function(b){this._procEntryField(b, "level","uint",8);this._procEntryField(b,"range_size","uint",24)})})};f.prototype._boxProcessors.stsd=function(){this._procFullBox();this._procField("entry_count","uint",32);this._procSubBoxes("entries",this.entry_count)};f.prototype._boxProcessors.subs=function(){this._procFullBox();this._procField("entry_count","uint",32);this._procEntries("entries",this.entry_count,function(d){this._procEntryField(d,"sample_delta","uint",32);this._procEntryField(d,"subsample_count","uint",16);this._procSubEntries(d, "subsamples",d.subsample_count,function(b){this._procEntryField(b,"subsample_size","uint",1===this.version?32:16);this._procEntryField(b,"subsample_priority","uint",8);this._procEntryField(b,"discardable","uint",8);this._procEntryField(b,"codec_specific_parameters","uint",32)})})};f.prototype._boxProcessors.tenc=function(){this._procFullBox();this._procField("default_IsEncrypted","uint",24);this._procField("default_IV_size","uint",8);this._procFieldArray("default_KID",16,"uint",8)};f.prototype._boxProcessors.tfdt= function(){this._procFullBox();this._procField("baseMediaDecodeTime","uint",1==this.version?64:32)};f.prototype._boxProcessors.tfhd=function(){this._procFullBox();this._procField("track_ID","uint",32);1&this.flags&&this._procField("base_data_offset","uint",64);2&this.flags&&this._procField("sample_description_offset","uint",32);8&this.flags&&this._procField("default_sample_duration","uint",32);16&this.flags&&this._procField("default_sample_size","uint",32);32&this.flags&&this._procField("default_sample_flags", "uint",32)};f.prototype._boxProcessors.tfra=function(){this._procFullBox();this._procField("track_ID","uint",32);this._parsing||(this.reserved=0,this.reserved|=(48&this.length_size_of_traf_num)<<4,this.reserved|=(12&this.length_size_of_trun_num)<<2,this.reserved|=3&this.length_size_of_sample_num);this._procField("reserved","uint",32);this._parsing&&(this.length_size_of_traf_num=(48&this.reserved)>>4,this.length_size_of_trun_num=(12&this.reserved)>>2,this.length_size_of_sample_num=3&this.reserved); this._procField("number_of_entry","uint",32);this._procEntries("entries",this.number_of_entry,function(d){this._procEntryField(d,"time","uint",1===this.version?64:32);this._procEntryField(d,"moof_offset","uint",1===this.version?64:32);this._procEntryField(d,"traf_number","uint",8*(this.length_size_of_traf_num+1));this._procEntryField(d,"trun_number","uint",8*(this.length_size_of_trun_num+1));this._procEntryField(d,"sample_number","uint",8*(this.length_size_of_sample_num+1))})};f.prototype._boxProcessors.tkhd= function(){this._procFullBox();this._procField("creation_time","uint",1==this.version?64:32);this._procField("modification_time","uint",1==this.version?64:32);this._procField("track_ID","uint",32);this._procField("reserved1","uint",32);this._procField("duration","uint",1==this.version?64:32);this._procFieldArray("reserved2",2,"uint",32);this._procField("layer","uint",16);this._procField("alternate_group","uint",16);this._procField("volume","template",16);this._procField("reserved3","uint",16);this._procFieldArray("matrix", 9,"template",32);this._procField("width","template",32);this._procField("height","template",32)};f.prototype._boxProcessors.trex=function(){this._procFullBox();this._procField("track_ID","uint",32);this._procField("default_sample_description_index","uint",32);this._procField("default_sample_duration","uint",32);this._procField("default_sample_size","uint",32);this._procField("default_sample_flags","uint",32)};f.prototype._boxProcessors.trun=function(){this._procFullBox();this._procField("sample_count", "uint",32);1&this.flags&&this._procField("data_offset","int",32);4&this.flags&&this._procField("first_sample_flags","uint",32);this._procEntries("samples",this.sample_count,function(d){256&this.flags&&this._procEntryField(d,"sample_duration","uint",32);512&this.flags&&this._procEntryField(d,"sample_size","uint",32);1024&this.flags&&this._procEntryField(d,"sample_flags","uint",32);2048&this.flags&&this._procEntryField(d,"sample_composition_time_offset",1===this.version?"int":"uint",32)})};f.prototype._boxProcessors["url "]= f.prototype._boxProcessors["urn "]=function(){this._procFullBox();"urn "===this.type&&this._procField("name","string",-1);this._procField("location","string",-1)};f.prototype._boxProcessors.vlab=function(){this._procField("source_label","utf8")};f.prototype._boxProcessors.vmhd=function(){this._procFullBox();this._procField("graphicsmode","uint",16);this._procFieldArray("opcolor",3,"uint",16)};f.prototype._boxProcessors.vttC=function(){this._procField("config","utf8")};f.prototype._boxProcessors.vtte= function(){}},{}],10:[function(g,k,l){(function(g){l.isArray=function(e){return Array.isArray?Array.isArray(e):"[object Array]"===Object.prototype.toString.call(e)};l.isBoolean=function(e){return"boolean"==typeof e};l.isNull=function(e){return null===e};l.isNullOrUndefined=function(e){return null==e};l.isNumber=function(e){return"number"==typeof e};l.isString=function(e){return"string"==typeof e};l.isSymbol=function(e){return"symbol"==typeof e};l.isUndefined=function(e){return void 0===e};l.isRegExp= function(e){return"[object RegExp]"===Object.prototype.toString.call(e)};l.isObject=function(e){return"object"==typeof e&&null!==e};l.isDate=function(e){return"[object Date]"===Object.prototype.toString.call(e)};l.isError=function(e){return"[object Error]"===Object.prototype.toString.call(e)||e instanceof Error};l.isFunction=function(e){return"function"==typeof e};l.isPrimitive=function(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"==typeof e||void 0===e}; l.isBuffer=g.isBuffer}).call(this,{isBuffer:g(22)})},{22:22}],11:[function(g,k,l){function h(){this._events&&Object.prototype.hasOwnProperty.call(this,"_events")||(this._events=n(null),this._eventsCount=0);this._maxListeners=this._maxListeners||void 0}function e(b,c,d,e){var f,g,m,k;if("function"!=typeof d)throw new TypeError('"listener" argument must be a function');return(f=b._events)?(f.newListener&&(b.emit("newListener",c,d.listener?d.listener:d),f=b._events),g=f[c]):(f=b._events=n(null),b._eventsCount= 0),g?("function"==typeof g?g=f[c]=e?[d,g]:[g,d]:e?g.unshift(d):g.push(d),g.warned||(k=void 0===b._maxListeners?h.defaultMaxListeners:b._maxListeners)&&0k&&(g.warned=!0,(m=Error("Possible EventEmitter memory leak detected. "+g.length+' "'+String(c)+'" listeners added. Use emitter.setMaxListeners() to increase limit.')).name="MaxListenersExceededWarning",m.emitter=b,m.type=c,m.count=g.length,"object"==typeof console&&console.warn&&console.warn("%s: %s",m.name,m.message))):(f[c]=d,++b._eventsCount), b}function f(){if(!this.fired)switch(this.target.removeListener(this.type,this.wrapFn),this.fired=!0,arguments.length){case 0:return this.listener.call(this.target);case 1:return this.listener.call(this.target,arguments[0]);case 2:return this.listener.call(this.target,arguments[0],arguments[1]);case 3:return this.listener.call(this.target,arguments[0],arguments[1],arguments[2]);default:for(var b=Array(arguments.length),c=0;cb||b!=b)throw new TypeError('"defaultMaxListeners" must be a positive number');z=b}}):h.defaultMaxListeners=z;h.prototype.setMaxListeners=function(b){if("number"!=typeof b||0>b||isNaN(b))throw new TypeError('"n" argument must be a positive number');return this._maxListeners=b,this};h.prototype.getMaxListeners=function(){return void 0===this._maxListeners?h.defaultMaxListeners:this._maxListeners};h.prototype.emit=function(b, c,d,e){var f,g,h;g="error"===b;if(h=this._events)g=g&&null==h.error;else if(!g)return!1;if(g){if(1f)return this;if(0===f)d.shift();else{g=f+1;for(var h=d.length;g>1,k=-7;b=f?b-1:0;var w=f?-1:1,l=g[e+b];b+=w;f=l&(1<<-k)-1;l>>=-k;for(k+=c;0>=-k;for(k+=d;0>1,Q=23===b?Math.pow(2,-24)-Math.pow(2,-77):0;c=d?0:c-1;d=d?1:-1;var X=0>e||0===e&&0>1/e?1:0;e=Math.abs(e);for(isNaN(e)||e===1/0?(h=isNaN(e)?1:0,m=l):(m=Math.floor(Math.log(e)/Math.LN2),1>e*(k=Math.pow(2,-m))&&(m--,k*=2),2<=(e+=1<=m+z?Q/k:Q*Math.pow(2,1-z))*k&&(m++,k/=2),l<=m+z?(h=0,m=l):1<=m+z?(h=(e*k-1)*Math.pow(2,b),m+=z):(h=e*Math.pow(2,z-1)*Math.pow(2,b),m=0));8<=b;g[f+c]=255&h,c+=d,h/=256,b-=8);m=m< elements at ("+this.line+","+this.column+ ")"),(C=new f).initFromNode(g,n),q.unshift(C)):"head"===g.local?(q[0]instanceof f||v(n,"Parent of element is not at ("+this.line+","+this.column+")"),null!==C.head&&v("Second element at ("+this.line+","+this.column+")"),C.head=new d,q.unshift(C.head)):"styling"===g.local?(q[0]instanceof d||v(n,"Parent of element is not at ("+this.line+","+this.column+")"),null!==C.head.styling&&v("Second element at ("+this.line+","+this.column+")"),C.head.styling=new b, q.unshift(C.head.styling)):"style"===g.local?q[0]instanceof b?((r=new c).initFromNode(g,n),r.id?C.head.styling.styles[r.id]=r:G(n,"